Is there a way to stop other subs from running while in a separate sub.
for instance say your in the sub
CreateNumber()
and the subs are setup like
CreateNumber()
AddNumber()
DeleteNumber()
Is there a way to be in CreateNumber() and call a function to stop AddNumber from running after creaetNumber() is finished? i just want my program to sit there to wait for an event to happen.
Just do this:
If you’re not using threads, then these Subs will simply be called in sequence, so you don’t have to do anything “clever”.
If you want CreateNumber to be able to control whether or not AddNumber() will be executed, then you can make it into a Function and return a result – e.g.
Then call it like this:
In this way, you only call the remaining Subs if CreateNumber() returned True.