Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Launching a macro from another macro in excel 1

Status
Not open for further replies.

Trident1

Technical User
May 24, 2005
13
GB
I have decided that I am duplicating an awful lot in my macros. I thought it would be a good idea to use smaller macros and use them one after the other. Assuming that I named these macros: a, b, c, d etc; I am trying to run them one after the other with:

Sub runalot()

runmacro: a
runmacro: c
runmacro: d

End Sub

When it starts to execute, I get a compile error message
"Duplicate declaration in current scope"

I'm sure the answer is simple and I'll once again look pretty stupid but I am very much a beginner compared to most of you guys!
 
Why not simply this ?
Call a()
Call b()
Call c()

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Thanks so much PH.
Another headache gone without the need for analgesia!

Trident
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top