Rusty
Registered User.
- Local time
- Today, 14:25
- Joined
- Apr 15, 2004
- Messages
- 207
Hello,
I have a date field on a form and I don't want the user to be able to enter a date that's in the future, i.e. not after today. I have tried using the code below and want the field to be blanked out and a message box to appear telling them that they can't do that.
Is it something like the code below plus:
DateOfEvent.Undo
MsgBox "You CANNOT enter a date which is AFTER today"
Please help,
Rusty
I have a date field on a form and I don't want the user to be able to enter a date that's in the future, i.e. not after today. I have tried using the code below and want the field to be blanked out and a message box to appear telling them that they can't do that.
Is it something like the code below plus:
DateOfEvent.Undo
MsgBox "You CANNOT enter a date which is AFTER today"
Please help,
Rusty

Code:
Private Sub DateOfEvent_AfterUpdate()
If (Me.DateOfEvent > Date) Then