Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Looping a macro
I want my macro to call on itself at the end and keep performing the loop 20
times. How can I do that? Any help will be much appreciated. TIA Sony |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Looping a macro
In , Sony
spake thusly: I want my macro to call on itself at the end and keep performing the loop 20 times. How can I do that? Any help will be much appreciated. You could, instead of calling the macro over and over, loop through the actions 20 time: Option Explicit Sub total_recall() For N = 1 To 20 'do something Next 'N End Sub Or if you wanted, you could have "do something" turn out to be to call a different macro. Option Explicit Sub total_recall() For N = 1 To 20 Application.Run "macro_name" Next 'N End Sub -dman- |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Looping a macro
That was a good alternative idea. Thank you Dallman Ross.
Sony "Dallman Ross" <dman@localhost. wrote in message ... In , Sony spake thusly: I want my macro to call on itself at the end and keep performing the loop 20 times. How can I do that? Any help will be much appreciated. You could, instead of calling the macro over and over, loop through the actions 20 time: Option Explicit Sub total_recall() For N = 1 To 20 'do something Next 'N End Sub Or if you wanted, you could have "do something" turn out to be to call a different macro. Option Explicit Sub total_recall() For N = 1 To 20 Application.Run "macro_name" Next 'N End Sub -dman- |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
Looping a macro
In , Sony
spake thusly: That was a good alternative idea. Thank you Dallman Ross. Good. Glad it helped. -dman- ============================== "Dallman Ross" <dman@localhost. wrote in message ... In , Sony spake thusly: I want my macro to call on itself at the end and keep performing the loop 20 times. How can I do that? Any help will be much appreciated. You could, instead of calling the macro over and over, loop through the actions 20 time: Option Explicit Sub total_recall() For N = 1 To 20 'do something Next 'N End Sub Or if you wanted, you could have "do something" turn out to be to call a different macro. Option Explicit Sub total_recall() For N = 1 To 20 Application.Run "macro_name" Next 'N End Sub -dman- |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
how do I email amacro? | Excel Worksheet Functions | |||
Closing File Error | Excel Discussion (Misc queries) | |||
Highlight Range - wrong macro, please edit. | Excel Worksheet Functions | |||
Looping Macro That adds a blank row between different part #'s | Excel Discussion (Misc queries) | |||
macro to browse for workbook, pick up data and looping | Excel Worksheet Functions |