control recording saving

9

904allen

I designing a form the feilds are bound. the form will be used by other
workers i want the form to update records using a update button but if the
user enters data and then decides that they don't want to update the
information. hqw can i prevent the update of the information entered on the
form when the user closes the form using the close button
 
L

Larry Linson

904allen said:
I designing a form the feilds are bound. the form will
be used by other workers i want the form to update
records using a update button but if the user enters
data and then decides that they don't want to update the
information. hqw can i prevent the update of the infor-
mation entered on the form when the user closes the
form using the close button.

The Command Button Wizard will give you the option to save the current
record, so your "Update" button will not require VBA code nor Access macros.

You are correct, that saving updates is automatic, on closing the form, on
moving to a different record, on taking explicit action to save, or on
moving from the main form into a subform control. However, there is a
BeforeUpdate event in which you can insert an Access macro or VBA code to
cancel the update... depending on your needs, you can either clear the
updates in the form, or you can just return to the form (this is often done
when you include code to validate the values entered, if one or more values
fail validation).

Larry Linson
Microsoft Access MVP
 

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

Top