Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

When close a form, do not auto save

Status
Not open for further replies.

GFullington

Programmer
Oct 7, 2003
18
US

Is there a way to prevent Access from automatically
saving a record when the form is closed?

When the form is initially opened, I am placing the user
at a new record; DoCmd.GoToRecord , , acNewRec.

When exiting the form, I am prompting the user via a
msgbox asking if they want to save the record. If the
user selects "No", I do not want to save the record.

I see one potential solution by deleting the record, but
was looking for a better way without having to delete.
 
G,

You can do a Me.Undo and that will remove the changes, or
you can reference the Me.SomeControl.OldValue property
of your controls.

Wayne
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top