S
SuperJas
Hi
I have a simple userform with 3 checkboxes, and I require that at least one checkbox has been checked. If this condition isn't met, then I'll show a message box to instruct this
My question is: How can I suspend the macro from processing the next line until this condition is met? (ie. After the user clicks OK on the msgbox, I'd like the userform to remain there so they can check the checkbox(es), and then click the "Run" button on the userform to resume the macro
My current code is as below
----------------------------------------------------
Private Sub cmdRun_Click(
If chk1 or chk2 or chk3 Then
Unload Me
DoEvent
<other code here...
Els
MsgBox "Please check at least one box", vbOKOnly + vbApplicationModal + vbCritical, "Selection Required
End I
End Su
I have a simple userform with 3 checkboxes, and I require that at least one checkbox has been checked. If this condition isn't met, then I'll show a message box to instruct this
My question is: How can I suspend the macro from processing the next line until this condition is met? (ie. After the user clicks OK on the msgbox, I'd like the userform to remain there so they can check the checkbox(es), and then click the "Run" button on the userform to resume the macro
My current code is as below
----------------------------------------------------
Private Sub cmdRun_Click(
If chk1 or chk2 or chk3 Then
Unload Me
DoEvent
<other code here...
Els
MsgBox "Please check at least one box", vbOKOnly + vbApplicationModal + vbCritical, "Selection Required
End I
End Su