Hi, I use Access 2010 with a lot of forms and many thousands of lines of VBA code. When searching manually thru the codelines in the various projects
I will find e.g. the following line of code (let's call it current line):
acPreview
While the cursor is inside this line I would like to create a new line of code behind the line with the cursor in.
The new line should be:
I will do the task by means of VBA-Code (a Sub), in which I will extract the information "320rpt_Mitglie derliste" and insert it in the new line.
My first question is: how can I start the Sub via Key-Combination? Can I use a key-combination while I am just seeing some lines of code?
My second question is: how can address the VBA-Project (me.???) and the line in which the cursor is (.lines???) ?
How can I insert the new line immediately behind the current line.
My VBA-knowledge is sufficent enough to extract the information "320rpt_Mitglie derliste" and build the string for the new line.
Thanks a lot for your help
I will find e.g. the following line of code (let's call it current line):
Code:
DoCmd.OpenReport "320rpt_Mitgliederliste",
While the cursor is inside this line I would like to create a new line of code behind the line with the cursor in.
The new line should be:
Code:
CreateLogFile2 "320rpt_Mitgliederliste", 4
My first question is: how can I start the Sub via Key-Combination? Can I use a key-combination while I am just seeing some lines of code?
My second question is: how can address the VBA-Project (me.???) and the line in which the cursor is (.lines???) ?
How can I insert the new line immediately behind the current line.
My VBA-knowledge is sufficent enough to extract the information "320rpt_Mitglie derliste" and build the string for the new line.
Thanks a lot for your help
Comment