View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Mike Q. Mike Q. is offline
external usenet poster
 
Posts: 49
Default One macro to rule them all

Put all the recorded macros you want to run in the Personal Macro Workbook in
one module. Then write a procedure to call the macros in the order you want
them.
Sub Main()
Call Macro1
Call Macro2
Call Macro3
End Sub

For you case of dizzy spells you can add the the begining of your Macros
"Application.ScreenUpdating = False" and "Application.ScreenUpdating = True"
at the end of your macro. BUT...test this first on each Macro. Your macro
may need of update in the middle to continue running.

--
Mike Q.


"gerbilspy" wrote:


New here, I've searched and researched, but have been unable to find the
answer to my question...so here goes: (I hope this isn't such a dumb
question that no one wants to bother with it!)

I have a series of macros I've recorded in a workbook, and now I want
to create a macro to run them all in sequence, and then create a
template that I can use anytime I get new data. I want to just import
the new data into my newly created document, and run the One Macro that
Rules them All, instead of having to run all 8 of them individually. I
am totally new to recording macros and I just was unable to do
everything in one great big macro.

I have tried to record the macro, and it works fine in the workbook,
but when I create a template from it and then create a new document off
the template, I get the error message: runtime error 1004 - it seems to
be looking for my macro in the template- which of course isn't opened.
The macro DOES work in the newly created document if I open the
template too, but I would like to be able to avoid that if possible.
I've tried putting the macro in a Personal Macro Workbook but that
didn't work either.

One more thing, is there a way to have the macro run but not be able to
see everything that it's doing? Makes me dizzy! :)

Thanks for you help!


--
gerbilspy
------------------------------------------------------------------------
gerbilspy's Profile: http://www.excelforum.com/member.php...o&userid=28047
View this thread: http://www.excelforum.com/showthread...hreadid=475520