Ugh, such ugly code. Have a look at the TCVM1 package to learn some REXX coding techniques. It is an HTML selfstudy.
2008/7/1 Huegel, Thomas <[EMAIL PROTECTED]>: > Not many comments to explain the code but here is an example. > > WAKEUP RESET > CP SET IMSG IUCV > CP SET MSG IUCV > . > . > . > . > . > > DATEOK: > FLDATE = RIGHT(DATE(S,TDATE,U),6) > SET CMSTYPE HT > TELL OPERATOR AT NODEID GET LOG FLDATE > WAKEUP '+00:00:15 (IUCVMSG' > IF RC = 2 THEN SIGNAL ERREXT3 > PULL RESPONSE > PARSE VAR RESPONSE MTYPE . MNO . SPNO . > IF FIND(RESPONSE,'DMSDSK002E') ¬=0 THEN SIGNAL ERREXT1 > WAKEUP '+00:00:15 (RDR ' > IF RC = 2 THEN SIGNAL ERREXT3 > DO FOREVER > SPNO = FIND(RESPONSE,'RDR FILE') > IF SPNO ¬= 0 THEN DO > SPNO = SPNO + 2 > SIGNAL PEEKIT > END > WAKEUP '+00:00:10 (IUCVMSG' > IF RC = 2 THEN SIGNAL ERREXT3 > PULL RESPONSE > PARSE VAR RESPONSE MTYPE . MNO . SPNO . > END > PEEKIT: > DESBUF > SPNO = WORD(RESPONSE,SPNO) > QUEUE COMMAND SET RESERVED 1 HI SEELOG NODEID TDATE > QUEUE COMMAND SET PF15 FFILE NODEID FLDATE > PEEK SPNO '(FOR * PROFILE PROFDISZ' > PURGE RDR SPNO > EXIT: > WAKEUP RESET > SET MSG ON > SET IMSG ON > EXIT > > -----Original Message----- > From: The IBM z/VM Operating System [mailto:[EMAIL PROTECTED] > Behalf Of Wakser, David > Sent: Tuesday, July 01, 2008 9:10 AM > To: IBMVM@LISTSERV.UARK.EDU > Subject: Best method > > > All: > > What is the best method to code, for a SVM, a wait for a file to > arrive in its reader? > > I have a (very old) EXEC that has a "do forever" loop with a > "EXECIO * CP (STEM" aa. "STRING CP Q RDR * ALL" command followed by a > SLEEP when no files are found. Is there a better method of "waking up" > an EXEC when a RDR file arrives? > > Thanks, in advance. > > David Wakser > -- Kris Buelens, IBM Belgium, VM customer support