$Cms: Difference between revisions
mNo edit summary |
mNo edit summary |
||
Line 1: | Line 1: | ||
{{DISPLAYTITLE:$Cms}} | {{DISPLAYTITLE:$Cms}} | ||
<span class="pageSubtitle" | <span class="pageSubtitle">Determine if online is running under CMS</span> | ||
<p class="warning">Most Sirius $functions have been deprecated in favor of Object Oriented methods. There is currently no OO equivalent for the $Cms function.</p> | <p class="warning">Most Sirius $functions have been deprecated in favor of Object Oriented methods. There is currently no OO equivalent for the $Cms function.</p> |
Revision as of 21:21, 22 November 2011
Determine if online is running under CMS
Most Sirius $functions have been deprecated in favor of Object Oriented methods. There is currently no OO equivalent for the $Cms function.
This function can be used to determine if the online is running under CMS.
The $Cms function accepts no arguments and returns either a 1 if the online is running under CMS or a 0 otherwise.
Syntax
<section begin="syntax" /> %CMS = $Cms <section end="syntax" />
This function can be used to test if running under CMS before running any operating system specific code. For example, the program
IF $Cms THEN %RC = $SETG('NEXTPROC', 'PROC.CMS') ELSE %RC = $SETG('NEXTPROC', 'PROC.MVS') END IF
would set global variable NEXTPROC to 'PROC.CMS' if running under CMS and to 'PROC.MVS', otherwise.