Not Allow Future Date

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a form where people are checking their co-workers work and reporting
any errors they find. I have a date field that must be in the past. Is
there a way to have an error message appear if a future date is entered?
Thanks for all of your help.
 
In the After Update event for the date textbox (I will call it
txtCheckDate), something like:

If Me.txtCheckDate >= Date Then
MsgBox "Date must be in the past"
Me.txtCheckDate.Undo
Cancel = True
End If
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top