ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   executing a macro within another (https://www.excelbanter.com/excel-discussion-misc-queries/97501-executing-macro-within-another.html)

brian

executing a macro within another
 
How can I call up macro1 to execute it inside macro2? Thanks for help.

Brian



Norman Jones

executing a macro within another
 
Hi Brian,

Try something like:

'=============
Public Sub Tester()

'Your code

Call Macro2

End Sub
'<<=============


---
Regards,
Norman


"brian" wrote in message
...
How can I call up macro1 to execute it inside macro2? Thanks for help.

Brian




Bob Phillips

executing a macro within another
 
Sub macro2()

Call macro1

End Sub

If macro1 has arguments,

Call macro1(Param1, param2)

--

HTH

Bob Phillips

(replace xxxx in the email address with gmail if mailing direct)

"brian" wrote in message
...
How can I call up macro1 to execute it inside macro2? Thanks for help.

Brian





brian

executing a macro within another
 
How easy it is if you are knowledgeable. Thank you Norman and Bob.

Brian

"brian" wrote in message
...
How can I call up macro1 to execute it inside macro2? Thanks for help.

Brian





All times are GMT +1. The time now is 02:15 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com