I want to add some data validation to a control, and keep the user there until the data is entered correctly. What I am trying to do is force a user to enter a correct date, based on another date field.
What's the best way to do this?
Thanks!
Dave
Code:
Private Sub Training_End_AfterUpdate() If [Training_End] > DateAdd("d", 1092, [Training_Start]) Then MsgBox "The Training End Date is greater than 156 weeks from the Training Start Date.", vbExclamation + vbOKOnly, "Error 101" End If End Sub
Thanks!
Dave
Comment