How to stop a macro while it is running ?

  • Thread starter Thread starter Srikanth
  • Start date Start date
S

Srikanth

Hi,

I want to be able to have a buttons which can pause,resume or stop a
macro while it is running. How ot implement it ? Your help is
appreciated. Thanks

Srikanth
 
You can use the Escape key and then have your code look for that interruption.

See VBA's help for EnableCancelKey. You'll see an example.
 

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

Back
Top