#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 468
Default Run multiple macros

Hi, is there any way i can run multiple macros located in diferent modules?
I want to have a button assigned to a macro and when i click it, the
multiple macro to run the macro in module 1, then the macro in module 2, then
the macro in module 3....
Can this be done?
Thanks!
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default Run multiple macros

Have the button connected to something like:

Sub MAIN()
Call Mac1
Call Mac2
Call Mac3
.......
End Sub


As long as the Mac's are not Private, you should be O.K.
--
Gary''s Student - gsnu200903


"puiuluipui" wrote:

Hi, is there any way i can run multiple macros located in diferent modules?
I want to have a button assigned to a macro and when i click it, the
multiple macro to run the macro in module 1, then the macro in module 2, then
the macro in module 3....
Can this be done?
Thanks!

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 468
Default Run multiple macros

Hi Gary,

"As long as the Mac's are not Private, you should be O.K."
I don't know so much to understand exactly what this refer to, but i receive
an error:
Compile error:
Sub or Function not defined.
I have 4 modules.
Module1
Module2
Module3
Main
Main module has your code.
What am i doing wrong?
Thanks!

"Gary''s Student" wrote:

Have the button connected to something like:

Sub MAIN()
Call Mac1
Call Mac2
Call Mac3
......
End Sub


As long as the Mac's are not Private, you should be O.K.
--
Gary''s Student - gsnu200903


"puiuluipui" wrote:

Hi, is there any way i can run multiple macros located in diferent modules?
I want to have a button assigned to a macro and when i click it, the
multiple macro to run the macro in module 1, then the macro in module 2, then
the macro in module 3....
Can this be done?
Thanks!

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Run multiple macros

Excel knows where the macros are so you don't have to designate modules.

Sub Call_All()
macro1
macro2
macro3
End Sub

On Thu, 17 Sep 2009 08:16:06 -0700, puiuluipui
wrote:

Hi, is there any way i can run multiple macros located in diferent modules?
I want to have a button assigned to a macro and when i click it, the
multiple macro to run the macro in module 1, then the macro in module 2, then
the macro in module 3....
Can this be done?
Thanks!


  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 468
Default Run multiple macros

Hi Gord i understand now. It's working.
Thanks allot!

"Gord Dibben" wrote:

Excel knows where the macros are so you don't have to designate modules.

Sub Call_All()
macro1
macro2
macro3
End Sub

On Thu, 17 Sep 2009 08:16:06 -0700, puiuluipui
wrote:

Hi, is there any way i can run multiple macros located in diferent modules?
I want to have a button assigned to a macro and when i click it, the
multiple macro to run the macro in module 1, then the macro in module 2, then
the macro in module 3....
Can this be done?
Thanks!





Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Using Macros To Perform Multiple Averages d__o__a Excel Worksheet Functions 7 July 3rd 09 09:24 AM
Run macros on data spread across multiple spreadsheets akapoor Excel Discussion (Misc queries) 2 September 11th 07 04:38 PM
Message box with multiple options running different macros Martin Excel Discussion (Misc queries) 3 July 23rd 07 12:19 PM
Using Multiple Tests and Sounds With Worksheet Macros Carl Excel Discussion (Misc queries) 3 July 1st 06 07:35 PM
creating macros in multiple worksheets Shana@KL Excel Worksheet Functions 0 August 26th 05 04:49 AM


All times are GMT +1. The time now is 07:31 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"