Greetings,
I've inherited an Access 97 database that I'm trying to convert to 2003. One of the Functions appears to have been written by Leo Tolstoy and it will not compile (too large). I know the function needs to be split up, but I'm not familiar enough with VBA to recognize logical break points to produce the sub functions. This thing is loaded to the brim with 'If...End If' statements.. so I'm wondering if the sections of code that are framed by the 'If' and 'End If' can be made into their own function or sub? Or are there other things I should look for to try and break it apart? Maybe breaking after a Loop?
I guess what I'm hoping is to be able to copy the If statements, put them in their own function, and then replace the original position with a call to that function.
Does that sound like a logical way to proceed?
Thanks in advance.
I've inherited an Access 97 database that I'm trying to convert to 2003. One of the Functions appears to have been written by Leo Tolstoy and it will not compile (too large). I know the function needs to be split up, but I'm not familiar enough with VBA to recognize logical break points to produce the sub functions. This thing is loaded to the brim with 'If...End If' statements.. so I'm wondering if the sections of code that are framed by the 'If' and 'End If' can be made into their own function or sub? Or are there other things I should look for to try and break it apart? Maybe breaking after a Loop?
I guess what I'm hoping is to be able to copy the If statements, put them in their own function, and then replace the original position with a call to that function.
Does that sound like a logical way to proceed?
Thanks in advance.