Hi All,
I have this bit of code in a Forms Before Update Event:
Private Sub Form_BeforeUpdate(Cancel As Integer)
If IsNull(Me.BatchDate) Then
MsgBox "BatchDate Must Not Be Left Blank!"
Cancel = True
BatchDate.SetFocus
End If
End Sub
Now I want to add a piece of code to this where it only displays this message if another field called 'Completed Date' is entered. So if CompletedDate is entered, then display message, if CompletedDate is blank, then DO NOT display message and let the user move on.
I have this bit of code in a Forms Before Update Event:
Private Sub Form_BeforeUpdate(Cancel As Integer)
If IsNull(Me.BatchDate) Then
MsgBox "BatchDate Must Not Be Left Blank!"
Cancel = True
BatchDate.SetFocus
End If
End Sub
Now I want to add a piece of code to this where it only displays this message if another field called 'Completed Date' is entered. So if CompletedDate is entered, then display message, if CompletedDate is blank, then DO NOT display message and let the user move on.