View previous topic :: View next topic
|
Author |
Message |
aprak00 Warnings : 2 New User
Joined: 09 Aug 2006 Posts: 24
|
|
|
|
please explain the difference between GOBACK, EXIT PROGRAM and STOP RUN? |
|
Back to top |
|
|
inr
New User
Joined: 08 Sep 2006 Posts: 1 Location: india
|
|
|
|
Exit : the control comes out of the program.
go back: the control goes to the OS
stop run:it indicates the end of the paragraph. |
|
Back to top |
|
|
guptae
Moderator
Joined: 14 Oct 2005 Posts: 1208 Location: Bangalore,India
|
|
|
|
Hi,
There is no difference in the function of STOP RUN or GOBACk if in a STANDALONE program. As soon the program executes, the control goes back to MVS.
But in case of Called program,
If Stop Run, the Control goes back to MVS which shouldn't be the case. where as for GoBack, the control goes to the Calling Program.
For the reason, we shouldn't code Stop Run for a Subroutine. |
|
Back to top |
|
|
vin12pr Warnings : 1 New User
Joined: 14 Jun 2006 Posts: 56
|
|
|
|
Stop Run : Is coded only in the main program and it returns the control back to the operating system.
GO back: Can be coded in main program and sub program and it returns teh control from where it received the control
Exit Program:Is coded in sub program and it returns the control to the main program. |
|
Back to top |
|
|
pankajupadhyay Warnings : 1 New User
Joined: 04 May 2007 Posts: 13 Location: pune
|
|
|
|
STOP RUN is the last executable statement of main program that give the control back to MVS/os.
EXIT is last executable statement of sub program that control back to main program.
GOBACK is not executable but last statement of any program which give the control back to "where it came" |
|
Back to top |
|
|
|