Is it possible to generate or modify VBA code on the fly, i.e., at runtime?
I'm using Outlook 2000, and I want to run a certain procedure at Startup, but only once a day at Startup, not every time Outlook is opened throughout the day. I thought the best way to do this would be to modify the code on the fly, say, the first line could be a Const that would tell the rest of the code whether to Exit Sub before the bulk of the code, or not.
Otherwise, I can find an external object in which to store this information, but that may present problems in code distribution. Someone else running my code might get confused with this extra object in one of their folders.
Designating a specific time of day, like 9:30 a.m., before which this code will run, is not an option.
Any help is much appreciated.
-Christopher
I'm using Outlook 2000, and I want to run a certain procedure at Startup, but only once a day at Startup, not every time Outlook is opened throughout the day. I thought the best way to do this would be to modify the code on the fly, say, the first line could be a Const that would tell the rest of the code whether to Exit Sub before the bulk of the code, or not.
Otherwise, I can find an external object in which to store this information, but that may present problems in code distribution. Someone else running my code might get confused with this extra object in one of their folders.
Designating a specific time of day, like 9:30 a.m., before which this code will run, is not an option.
Any help is much appreciated.
-Christopher