Avatar of davsay
davsay
 asked on

Exiting Subs

I have a number of sub routines all called one by one from a kind of master sub. I have an exit sub statement in the first sub (based on a value from an inputbox) - my question is: can i get the code to completely stop altogether, rather than quitting that particular sub and going to the next. I guess i could put code in the other subs to text the condition also, but there's about six of them. Suppose i'm being lazy really, but just wondered if you clever people have a quick way. Thanks.

Ps. and what happened to posting 10 point questions on this thing?
Programming

Avatar of undefined
Last Comment
davsay

8/22/2022 - Mon
Arthur_Wood

what programming language are you using?

AW
ASKER CERTIFIED SOLUTION
ksokolowski

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
davsay

ASKER
Ok, (this was in Excel VBA by the way).

I think i have it, inspired by K's answer so you can have the points. This was way easier than i first thought and really my question was probably misguided. Things seem much clearer this morning. To remedy the situation I just put a condition in the main sub (the one that calls the others). The original test condition was in the first sub (that actually did something) I incorrectly thought it would run through all the otehrs, but of course it goes back to the main sub to get its next direction. Silly me.

Thanks.  
 
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck