Prevent form from updating when an error message occur

dealwi8me

Registered User.
Local time
Today, 09:19
Joined
Jan 5, 2005
Messages
187
Hello all,

I have 5 check boxes on a form and one of them must be checked in order to get the correct result.
If the user does not check any of the the five checkboxes he gets a msgbox telling him that he must checks one of the checkboxes.

What i want to ask is if is possible to prevent the form from updating? Because the user gets the error message but after that the form is being updated even though he hasn't check any of the fields.

Thank you in advance!
 
In Sub Form_BeforeUpdate, after message
put Cancel = True
 
thanks that works fine:)
 

Users who are viewing this thread

Back
Top Bottom