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 John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Cancel Button 1

Status
Not open for further replies.

mrkshpntf

MIS
Apr 19, 2007
92
US


Is there a way to NOT get a 'action was canceled' prompt when cancel button is clicked on a parameter form?

Thanks,
mrkshpntf.
 
Do you mean error 2001? it is a trappable error. You can use an error trap.
 
Remou,

Let me explain:

I have a command button on a form that generates a report when clicked.

When the command button is clicked, a parameter form appears where the user has to enter the date for which the data is required.

I want the users to exit (if they choose to and click on 'cancel') without getting confused by the 'OpenReport action was canceled' prompt.

I don't see 'error 2001' mentioned on the prompt.

I hope this explanation helps.

Thanks,
mrkshpntf.
 
Ok, that is a different error number, 2501 as far as I recall.
 


Remou,

I got it.

I removed - MsgBox Err.Description - from the code.

The message box doesn't appear anymore.

Thanks,
mrkshpntf.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top