Macro linking

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have doubt with macro coding.
I have three macros to run.
In first step: If user press a macro button it has to run the Macro1, after
running this, there is one message box will popup asking for “Yes†or “Noâ€
Now question is If user select “Ok†it should run the macro2 and If user
select “No†it should run the macro3.
Just I want to know how to link the Macro 2 and Macro3 after message box
message button.
I hope this make sense.
Regards,
Vishu
 
One way to do this is to write a "Master" macro that calls Macro1,
Macro2, and Macro3 according to the logic you describe. Perhaps
something along the lines of

Sub Master()
Ask question 1
If User say Yes then
Macro1
endif

Ask Question 2
If User say Yes then
Macro2
endif

Ask Question 3
If User say Yes then
Macro1
endif
end sub
 
Back
Top