Chapter Contents |
Previous |
Next |
ENVIRONMENT |
Abbreviation: | ENV |
Syntax | |
Details | |
Example | |
See Also |
Syntax |
ENVIRONMENT <<entry-name\><line-num> | RUN> |
Details |
The ENVIRONMENT command enables you to display and modify the source program (that is, it sets a developer debugging environment) for any program in the application's execution stack while another program is active. When a developer environment is set, the debugger generates messages showing both the current program environment and the developer environment. In the developer environment, you can scroll through the source program, set debugging requests, and operate on the variables. For example, while TEST2.SCL is active, the ENVIRONMENT command enables you to display the source code for TEST1.SCL, reset the values of several variables in TEST1.SCL, and then return to TEST2.SCL.
By default, when you issue the ENVIRONMENT command from the current executing program without options, it sets the current program environment as the developer environment. If you issue the ENVIRONMENT command without an argument from a program other than the current program, the developer environment is reset to the program line containing the CALL DISPLAY statement.
Setting a developer environment does not change the way a program executes.
To return control to the active program, use the ENV RUN command to reset the environment to the active program, or use the GO, STEP or JUMP command to leave the developer environment and resume execution.
Example |
Assume that an execution stack looks like this:
TEST3.SCL line 37 TEST2.SCL line 24 TEST1.SCL line 10The following examples illustrate valid ENVIRONMENT commands and describe their effect on the preceding execution stack:
DEBUG> env test1.scl\10
The output to the debugger MESSAGE window is
env test1.scl\10 Stop at line 37 in MYLIB.MYCAT.TEST3.SCL Developer environment at line 10 in MYLIB.MYCAT.TEST1.SCL
DEBUG> env test2\45
DEBUG> env run
DEBUG> env test4\
Because TEST4.SCL is not in the SCL execution stack, the SOURCE window still displays TEST3.SCL. The output to the debugger MESSAGE window is
Program TEST4 is not active
See Also |
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.