RTVACTSBS RETRIEVE ACTIVE SUBSYSTEMS TAAJOCU |
The Retrieve Active Subsystems command retrieves the active
subsystems on the system and returns them in a large variable. Each
20 byte entry is made up of the subsystem name and library. The
number of active subsystems and the controlling subsystem/library are
also returned.
The QWCLASBS API is used internally.
A typical series of commands would be:
DCL &RTNSBS *CHAR LEN(9800)
DCL &NBRSBS *DEC LEN(5 0)
DCL &SX *DEC LEN(5 0)
DCL &CHAR20 *CHAR LEN(20)
DCL &SBSD *CHAR LEN(10)
DCL &SBSDL *CHAR LEN(10)
.
RTVACTSBS RTNSBS(&RTNSBS) NBRSBS(&NBRSBS)
CHGVAR &SX -19
LOOP: CHGVAR &SX (&SX + 20)
IF (&SX *LT 9781) DO /* Within area */
CHGVAR &CHAR20 %SST(&RTNSBS &SX 20)
IF (&CHAR20 *NE ' ') DO /* Active sbs */
CHGVAR &SBSD %SST(&CHAR20 1 10)
CHGVAR &SBSDL %SST(&CHAR20 11 10)
/****************************/
/* */
/* Your processing */
/* */
/****************************/
GOTO LOOP
ENDDO /* Active sbs */
ENDDO /* Within area */
RTVACTSBS escape messages you can monitor for
---------------------------------------------
TAA9892 More than 490 active subsystems exist
Escape messages from based on functions will be re-sent.
Command parameters *CMD
------------------
RTNSBS An optional return variable for the active
subsystems. Each active subsystem takes 20 bytes
with the first 10 as the subsystem name and the last
10 as the subsystem library. If used, it must be
declared as *CHAR LEN(9800).
A maximum of 490 subsystems may be returned.
If less than 490 exist, the remaining space is
blank.
NBRSBS An optional return variable for the number of active
subsystems. If used, it must be declared as *DEC
LEN(5 0).
CTLSBSD An optional return variable for the name of the
controlling subsystem. If used, it must be declared
as *CHAR LEN(10).
CTLSBSDLIB An optional return variable for the name of the
controlling subsystem library. If used, it must be
declared as *CHAR LEN(10).
Restrictions
------------
The command sends an escape message if more than 490 subsystem exist.
Because the command returns variables, it may only be used in a CL
program.
Prerequisites
-------------
The following TAA Tools must be on your system:
CRTUSRSPC Create user space
EDTVAR Edit variable
SNDESCMSG Send escape message
Implementation
--------------
None, the tool is ready to use.
Objects used by the tool
------------------------
Object Type Attribute Src member Src file
------ ---- --------- ---------- ----------
RTVACTSBS *CMD TAAJOCU QATTCMD
TAAJOCUC *PGM CLP TAAJOCUC QATTCL
|
Added to TAA Productivity tools February 28, 2000