-
Prevent sub routines from running
Is there any code to prevent sub routines running?
I have a user form that displays records and it that uses various controls with code activating on change events.
I also have a button which resets the form to allow a new entry to be added, but I want to disable the on chnage routines.
Is this possible?
ie
On cmdButton click ignore Private Sub cboType_Change()
TIA
-
I do it with a simple flag, like so
[vba]
If Not fReEntry Then
fReEntry = True
'do the event stuff
fReEntry = False
Endif
[/vba]
and then I can set that flag in mu=y code elsewhere.
It works but is cumbersome, as you have to add it to all such events.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules