Cancelling a New Record Entry

S

Steph

I need a button ("Cancel") on my AddInsertionOrder form
that:

a) Undos any information that was entered (if any)
b) Closes the form
 
A

Allen Browne

Private Sub cmdCancel_Click()
If Me.Dirty Then
Me.Undo
End If
DoCmd.Close acForm, Me.Name
End Sub
 
Top