Re: pattern for an error
- From: "William M. Klein" <wmklein@xxxxxxxxxxxxxxxxx>
- Date: Wed, 28 May 2008 12:52:34 GMT
You should only return from the PERFORM of a routine with an EXIT PROGRAM, if
the executing program is a MAIN program. If you don't leave from a sub-program,
then there is a bug - or something else you aren't telling us.
Depending on the compiler, you might want to replace EXIT PROGRAM with GOBACK.
When available (it was an extension to the '85 Standard - but a common one that
is now Standard), you will "go up a level" from a subprogram and will "stop run"
from a main program.
If you STILL get to the DISPLAY, then there must be something going on that you
haven't told us about.
--
Bill Klein
wmklein <at> ix.netcom.com
"mario" <mmc_vw1200@xxxxxxxxxxx> wrote in message
news:af17cd6e-a738-4718-80f6-c1c4376446a6@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
i already tried but "exit program" does no exit
for example
gogogo.
display "hi"
perform error_occurs
display "hi after error"
.
error_occurs
exit program
.
i come back to the second display "hi after error" so the "EXIT
PROGRAM" does not realy that what it sould right???
.
- References:
- pattern for an error
- From: mario
- Re: pattern for an error
- From: Robert
- Re: pattern for an error
- From: mario
- pattern for an error
- Prev by Date: Re: pattern for an error
- Next by Date: Re: Opinions on approach, please...
- Previous by thread: Re: pattern for an error
- Next by thread: Re: pattern for an error
- Index(es):
Relevant Pages
|