Hi,
I created a form with 4 check Boxes. Each Check boxe run a Macro. I put the following code in a button called(RunMacros):
Private Sub RunMacros_Click()
If Me.Check1 = True Then
DoCmd.RunMacro "Macro1"
If Me.Check2 = True Then
DoCmd.RunMacro "Macro2"
If Me.Check3 = True Then
DoCmd.RunMacro "Macro3"
If Me.Check4 = True Then
DoCmd.RunMacro "Macro4"
Else
MsgBox "Select Macro", vbExclamation, "Macros"
End If
End If
End If
End If
End Sub
It's working when I choose to run check1, Check2, Check3 and Check4 (In that sequence) or Check1 and Check2. The problem I am having is I can not make it run Check1 and Check 4 or Check2, Check4, etc...
Please Help
Thanks in Advance
Ismail
I created a form with 4 check Boxes. Each Check boxe run a Macro. I put the following code in a button called(RunMacros):
Private Sub RunMacros_Click()
If Me.Check1 = True Then
DoCmd.RunMacro "Macro1"
If Me.Check2 = True Then
DoCmd.RunMacro "Macro2"
If Me.Check3 = True Then
DoCmd.RunMacro "Macro3"
If Me.Check4 = True Then
DoCmd.RunMacro "Macro4"
Else
MsgBox "Select Macro", vbExclamation, "Macros"
End If
End If
End If
End If
End Sub
It's working when I choose to run check1, Check2, Check3 and Check4 (In that sequence) or Check1 and Check2. The problem I am having is I can not make it run Check1 and Check 4 or Check2, Check4, etc...
Please Help
Thanks in Advance
Ismail