B
Bob Quintal
=?Utf-8?B?c2N1YmFkaXZlcg==?=
If MeAct_dept!<> null will not work
Replace it with
If (Not isnull(Me!Act_Dept)) AND isnull)Me!Act_Subd_ then
I have three combo boxes in a form
Act_Dept
Act_Subd
Act_User
The 2nd and 3rd have the following code:
If IsNull(Me!Act_Subd) Then
MsgBox "You must fill in the subdepartment",
vbCritical Cancel = True
Me!Act_Subd.SetFocus
End If
If IsNull(Me!Act_User) Then
MsgBox "You must fill in the user name", vbCritical
Cancel = True
End If
Now I only want these codes to fire when Act_Dept is not null.
I have tried added an extra line but it doesn't seem to work.
If Me!Act_Dept <> Null and IsNull(Me!Act_Subd) Then
MsgBox "You must fill in the subdepartment",
vbCritical Cancel = True
Me!Act_Subd.SetFocus
End If
Cheers
If MeAct_dept!<> null will not work
Replace it with
If (Not isnull(Me!Act_Dept)) AND isnull)Me!Act_Subd_ then