Close form without saving changes

  • Thread starter Thread starter Kaylen
  • Start date Start date
K

Kaylen

Can anyone help me with a code so that users of my databse can close the form
or click cancel and all the changes to the record can be disregarded? I know
that closing the form automatically save the changes. I would like an option
or command button or code that allows exiting the form without saving the
changes. Please help. Thank you.
 
Undo only undo the last typed changes. I would like a Cancel button so the
user can cancel all the changes after typing a whole lot of text.
 
Hmmm? Perhaps I'm confused. I thought I used undo to clear all the fields
(i.e., the record).

Yes, here's the code behind an <Undo> button on one of my forms:

If Me.Dirty Then
Me.Undo
End If

So maybe Me.Undo rather than DoCmd.Undo...

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
Back
Top