G
Guest
With one particular form, this procedure works on step-through but fails on
run:
Private Sub CancelBttn_Click()
DoCmd.Close
Call ToggleStaffDropDn("Off")
Call ToggleBttn("Zero")
End Sub
The Toggle... items are utility procedures which reset some controls on the
Main form (which opened the failing form.) I use them repeatedly elsewhere.
The error message says the "expression requires that the control be in the
active window."
The exact same Cancel procedure works every time on another, very similar
form. I have this problem only with one form. I have added a line to set
the focus to the Main form, but it didn't help.
I am at a loss on this! Where could the problem lie?
Thanks!
run:
Private Sub CancelBttn_Click()
DoCmd.Close
Call ToggleStaffDropDn("Off")
Call ToggleBttn("Zero")
End Sub
The Toggle... items are utility procedures which reset some controls on the
Main form (which opened the failing form.) I use them repeatedly elsewhere.
The error message says the "expression requires that the control be in the
active window."
The exact same Cancel procedure works every time on another, very similar
form. I have this problem only with one form. I have added a line to set
the focus to the Main form, but it didn't help.
I am at a loss on this! Where could the problem lie?
Thanks!