J
~Jenny
Greetings. Last week I found out how to add lines of code
to a module while the program is running, but there is a
catch. Every time I do this my variables seem to get
reset as if I am entering the program for the first time.
I cheat by storing the values of these variables in a
spreadsheet and I reset all the variables after I insert
the code.
Why do my variables get reset when I use this command and
can I prevent that from happening?
ActiveWorkbook.VBProject.VBComponents
("Code_Module").CodeModule.InsertLines(3, "Hello")
~Jenny
to a module while the program is running, but there is a
catch. Every time I do this my variables seem to get
reset as if I am entering the program for the first time.
I cheat by storing the values of these variables in a
spreadsheet and I reset all the variables after I insert
the code.
Why do my variables get reset when I use this command and
can I prevent that from happening?
ActiveWorkbook.VBProject.VBComponents
("Code_Module").CodeModule.InsertLines(3, "Hello")
~Jenny