Guardian Programmer's Guide

Table Of Contents
Writing a Command-Interpreter Monitor ($CMON)
Guardian Programmer’s Guide 421922-014
23 - 66
Sample $CMON Program
!------------------------------------------------------------
! Procedure to save the Startup message in the global data
! area.
!------------------------------------------------------------
PROC SAVE^STARTUP^MESSAGE(RUCB,START^DATA,MESSAGE,
LENGTH,MATCH)VARIABLE;
INT .RUCB;
INT .START^DATA;
INT .MESSAGE;
INT LENGTH;
INT MATCH;
BEGIN
! Copy the Startup message into the CI^STARTUP structure:
CI^STARTUP.MSGCODE ':=' MESSAGE[0] FOR LENGTH/2;
MESSAGE^LEN := LENGTH;
END;