autostart and "on" and "off" macro

G

grime

Hopefully an easy one for all you gurus out there... :)

I have a macro, the contents of which aren't really necessary to post
here. I want that macro to "autostart" when the workbook is opened and
continue to repeat. I also need a seperate macro to break the loop and
stop the macro, and another to restart it (from the beginning).

Any help is much appreciated.
 
G

grime

Thanks for the reply, Tom, but this isn't exactly my intention.

Here is my current macro (which works, i suppose, but there may be a
more elegant way)...


Code:
 
T

Tom Ogilvy

If you can get macro2 to run when macro1 is running, then I suppose that is
fine. I don't see the point of calling macro1 when you have set the variable
to off.

I think the references I gave your are better, but it depends on what you
are doing and how much time macro1 takes to run and if it needs to be run as
much as you have it run.

Also, what your are doing may better be handled with events - again, I don't
know what you are doing.
 

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