Code running order

S

Santiago

Hi guys,

I'm quite new on this so probably this is too easy...
how can I make some Subs run in order but winting for the previous one to
finish what it is doing? for example:

call SUB1
call SUB2
call SUB3

I want each sub to start when the last one finishes executing. is this
possible?

I could put the "call SUB2" inside SUB1 (at the end) and that would maybe
solve it, but not in all cases...

Thanks & Bregards

Santiago
 
F

Fred

I do this exact thing with about 25 subs.

I simply have a master sub like JNW sugested but I just list all my
subs in it:

Sub master()
Call sub1
Call sub2
Call sub3
Call sub4
etc..
End Sub

After Sub1 runs control is returned to the master sub which then
executes Sub2, Sub2 runs and then control goes back to master which
then exucutes Sub3 and so on.

Fred
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top