T
Tony Williams
I have an unbound form that is used to input parameters for a query. On the
form I have a Cancel button in the event the user changes their mind. The
code on the Onclick property is
Private Sub cmdcancel_Click()
On Error GoTo Err_cmdcancel_Click
DoCmd.DoMenuItem acFormBar, acEditMenu, acUndo, , acMenuVer70
Exit_cmdcancel_Click:
Exit Sub
Err_cmdcancel_Click:
MsgBox Err.Description
Resume Exit_cmdcancel_Click
End Sub
However when I click on the button to cancel the input I get an error
message that says
Command or action 'Undo' isn't available now. Is this because the form is
unbound and if so what code can I use to cancel the input?
Thanks
Tony
form I have a Cancel button in the event the user changes their mind. The
code on the Onclick property is
Private Sub cmdcancel_Click()
On Error GoTo Err_cmdcancel_Click
DoCmd.DoMenuItem acFormBar, acEditMenu, acUndo, , acMenuVer70
Exit_cmdcancel_Click:
Exit Sub
Err_cmdcancel_Click:
MsgBox Err.Description
Resume Exit_cmdcancel_Click
End Sub
However when I click on the button to cancel the input I get an error
message that says
Command or action 'Undo' isn't available now. Is this because the form is
unbound and if so what code can I use to cancel the input?
Thanks
Tony