cancel dialog error

J

Joe Harman

In the Err_Hand: section you might want to trap the
specific error with an If ... then ... else expression.
Otherwise, you may never know if there is a different
error occurring. In your case, it might not be necessary
but, in general, you'd want to know. For example,
assuming that the error you're expecting is error number
35:

Err_Hand:
If err.number = 35 then
Application.Quit acPrompt
else
msgbox err.Number & " " & err.Description
end if
end sub

Joe
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top