Posted by Barbara Brazil on December 29, 2006 at 09:54:29:
In Reply to: Re: CW.CreateAutoModeDialog posted by Mike Saunders on December 29, 2006 at 09:33:37:
Mike:
There is a more accurate way to detect whether you should STOP or EXIT at the end of your program. Simply checking ENTERLEVEL may not be enough since program A may be ENTERED, then RUN program B. When it's time to leave program B, ENTERLEVEL will be > 0 but program B was not itself ENTERED.
Instead, check RUNSTATE. If RUNSTATE = 6, that means the current program was ENTERED.
bb