Category : OS/2 Files
Archive   : REXEXMPL.ZIP
Filename : SERVER.CMD
Date: June 11, 1991
Sample REXX Code: Queue Server
Function:
Create a private queue "FRED"
Set this to be the current Queue
DO FOREVER
Wait for data to appear on the private Queue
Read it in
Say it
END
How to Use:
This is a simple bit of sample code to show how to set up an interprocess
communication session between two OS/2 sessions using the REXX Queue.
(1) Open a text session and run SERVER.CMD. Alternatively,
you could issue the command START PMREXX SERVER.CMD to run the
server in a PM session.
(2) Open another text session and pipe the output from any command
into the RXQUEUE filter utility and specify the private queue
named FRED. For example,
dir | rxqueue fred
or strip off the extraneous stuff and just get the file names:
dir /f | rxqueue fred
Author: Jay A. Tunkel
IBM Corporation
OS/2(tm) Architecture and System Design
Compuserve: 76307,502
internet: [email protected]
***************************************************************************/
qid = rxqueue("Create","FRED") /* Create a private queue */
say qid /* just for fun, look at the internal*/
/* queue ID */
oldqname = rxqueue("Set","FRED") /* Change the current queue to the */
/* one that was just created */
say oldqname /* What was the old name? */
do forever
data = linein("QUEUE:") /* Wait for data, then read it in */
say data
end
Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!
This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.
But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/