I have an unbound text box that the user will enter a date for service. That date must be between the AuthStart and AuthEnd dates. I have been playing with this for a while and just can't get it to work. What am I doing wrong?
Private Sub Date_BeforeUpdate(Cancel As Integer)
If Not (Me!Date >= Int(Me!AuthStart) And Me!Date <= Int(Me!AuthEnd)) Or IsNull(Me!Date) Then
MsgBox "This date is not authorized"
Cancel = True
End If
End Sub
Thanks for your help
Private Sub Date_BeforeUpdate(Cancel As Integer)
If Not (Me!Date >= Int(Me!AuthStart) And Me!Date <= Int(Me!AuthEnd)) Or IsNull(Me!Date) Then
MsgBox "This date is not authorized"
Cancel = True
End If
End Sub
Thanks for your help