Going back to the old value

yhgtbfk

Registered User.
Local time
Tomorrow, 00:31
Joined
Aug 30, 2004
Messages
123
I want to do the following:

If user enters dumb value Then

Go back to the old value

Else

Do some code

End If

For example...

Imagine there is a text field called city and currently has the city name

If the user enters something, I want it to revert back to the name of the city that was there before the user entered the data.
 
y,

Use the AfterUpdate event and if the test fails, then just set:

Me.MyField = Me.MyField.OldValue

Wayne
 
y,

One more thought. .OldValue is only available for bound fields.

Wayne
 

Users who are viewing this thread

Back
Top Bottom