Free-Form Syntax | RESET{(E)} {*NOKEY} {*ALL} name |
Code | Factor 1 | Factor 2 | Result Field | Indicators | ||
---|---|---|---|---|---|---|
RESET (E) | *NOKEY | *ALL | name (variable or record format) | _ | ER | _ |
The RESET operation is used to restore a variable to the value held at the end of the *INIT phase. This value is called the reset value. If there is no *INZSR subroutine, the reset value is the same as the initial value (either the value specified by the INZ{(initial value)}, or the default value). If there is a *INZSR subroutine, the reset value is the value the variable holds when the *INZSR subroutine has completed.
The RESET operation can also be used to restore all the fields in a record format to their reset values.
See Figure 1 for more information on the *INIT phase.
To handle RESET exceptions (program status code 123), either the operation code extender 'E' or an error indicator ER can be specified, but not both. For more information on error handling, see Program Exception/Errors.
For more information, see Initialization Operations.