On my form i have a couple of fields that shouldn't contain a Null value.
I can't seem to figure out where to put my code with displaying a msgbox if a value is null. I tried the Before_Update event, but nothing ever happens.
I want this msgbox to pop up right after a field is bypassed and not filled out.
Dim strMsg As String, strTitle As String
Dim intStyle As Integer
If IsNull(Me!Combo0) Or Me!Combo = "" Then
strMsg = "You must pick a project."
strTitle = "Project Name Required"
intStyle = vbOKOnly
MsgBox strMsg, intStyle, strTitle
Cancel = True
End If
Any ideas?
Thanks!
I can't seem to figure out where to put my code with displaying a msgbox if a value is null. I tried the Before_Update event, but nothing ever happens.
I want this msgbox to pop up right after a field is bypassed and not filled out.
Dim strMsg As String, strTitle As String
Dim intStyle As Integer
If IsNull(Me!Combo0) Or Me!Combo = "" Then
strMsg = "You must pick a project."
strTitle = "Project Name Required"
intStyle = vbOKOnly
MsgBox strMsg, intStyle, strTitle
Cancel = True
End If
Any ideas?
Thanks!
Last edited: