SYS_LAST_RESTART_TEXT
Use the SYS_LAST_RESTART_TEXT script function to retrieve the text of the previous restart point defined in the script.
Notes:
- Use the :RESTART script statement to set restart points.
- Restart points define the line from which the script is processed when the task restarts.
Syntax
SYS_LAST_RESTART_TEXT ()
Return Codes
- The script function returns the text of the restart point that has last been passed.
- If no text has been defined for the last restart point, the script function returns the name of the restart point (Restart Point Name).
- If no restart point has been specified, the script function returns a blank.
Examples
The first restart point in the following example has a text (Program directory). The script writes the text in the activation report.
:RESTART BIN, "Program directory"
COPY C:\AEG\BIN\*.* C:\BACKUP\AEG\BIN\*.* /Y
:INC DOS.ERRORLEVEL
:SET &RET# = SYS_LAST_RESTART_TEXT()
:PRINT "Last restart point: &RET#"
:RESTART DB,
"Database directory"
XCOPY C:\AEG\DB\*.* C:\BACKUP\AEG\DB\*.* /E /Y
:INC DOS.ERRORLEVEL
The restart point in the following example does not have a text. The script writes the following phrase in the activation report: Restart Point BIN.
:RESTART BIN
:SET &RET# = SYS_LAST_RESTART_TEXT()
:PRINT &RET#
See also: