NET/MASTER Network Control Language (NCL) Programmer's Guide

Sending a Message to an NCL Process Using the INTQ Command
Environments and Command Processing
16–42 106160 Tandem Computers Incorporated
Example of the INTQ
Command
The following NCL procedure shows how to use INTQ from the OCS command input
line to send a message to an NCL process. This NCL procedure waits for messages to
arrive on its request queue. It reads each message, using INTREAD. It passes each
message to the next higher level environment, using INTCONT. To see how this NCL
procedure works, follow these steps:
1. Type the NCL procedure as shown, calling it ZEX1613N:
zex1613n: PROCEDURE
/* Receives messages on dep. request queue */
/* from an INTQ command sent from the OCS */
/* command input line. */
ON ERROR FLUSH
SAY "NCL ID of ZEX1613N is "&SYS.NCLID
DO FOREVER
INTREAD WAIT=YES TYPE=REQ
INTCONT COLOR=RED HLITE=BLINK
END
END zex1613n
2. Execute ZEX1613N from the OCS command input line using the START
command:
START ZEX1613N
Observe the NCL ID of ZEX1613N, because you must enter this as a parameter
when you use the INTQ command to send it a message. You will use the NCL ID
to flush the NCL process later. (You can also determine the NCL ID of an NCL
process by using the SHOW NCL command.)
3. Send a message to ZEX1613N, using the following command from the OCS
command input line:
INTQ ID=
nclid
DATA=This is a test message from OCS
Replace
nclid
with the NCL ID you obtained in Step 2.