Hi VJOSHI,
Try the following code, which is also in the attached file.
There are global variables in the Ordinary Code module that store:
a. If the specific timer is enabled
b. The Start Time for that timer
I changed the storage type to Double for the Timers, because that seems to be the data type that is usually used. My personal coding style is to put as little code in the UserForm module as possible, because it seems to be a lot easier for me to debug.
My UserForm has the following control names that are used by the code:
a. LabelTimer1 - Timer1 display
b. LabelTimer2 - Timer2 display
c. CommandButton1 - Starts Timer2
d. CommandButton2 - Stops Timer2
e. CommandButton3 - Resets Timer2
UserForm1 module code:
Ordinary module code (such as Module1):
I hope this helps.
Lewis
Bookmarks