Skip a Macro

  • Thread starter Thread starter Vick
  • Start date Start date
V

Vick

I have a worksheet_selection change macro, that I would like to skip if
another Macro is running, is that possible? Is it possible to tell if a macro
is commanding the change or the user?

Thanks
 
Vick,

Try this

Application.EnableEvents = False
'Your code
Application.EnableEvents = True

Mike
 
If you have a macro that causes the worksheet_selection change event to fire,
you can tell excel to stop monitoring these changes.

In your macro

application.enableevents = false
selection.offset(1,0).select 'or whatever your code does
application.enableevents = true

But even better would be to change your macro so that it's not selecting
anything when it runs. There aren't many things that have to be selected to
work on them.
 
Back
Top