Here's the job I'm using to run a REXX to create a CONSOLE and obtain the message response in an array.
//STEP010 EXEC PGM=IKJEFT01,PARM='%ULOGREX'
//SYSEXEC DD DISP=SHR,DSN=TECH.ZMSSAV.PROCLIB
//SYSTSPRT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSTSIN DD DUMMY
//SYSEXEC DD DISP=SHR,DSN=TECH.ZMSSAV.PROCLIB
//SYSTSPRT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSTSIN DD DUMMY
Address TSO
"CONSPROF SOLDISP(YES) UNSOLDISPLAY(YES) SOLNUM(400)"
"CONSOLE ACTIVATE,NAME(DIS1)"
/* "CONSOLE SYSCMD(#SQ VOL,9000,INV_TRKS) CART('MAINT')" */
"CONSOLE SYSCMD(D R,R) CART('maint')"
SAY "Return code = "RC
getcode = GETMSG('msg.','either','maint',,10)
SAY "GETMSG ended with "getcode
"CONSOLE DEACTIVATE"
"CONSPROF SOLDISP(YES) UNSOLDISPLAY(YES) SOLNUM(400)"
"CONSOLE ACTIVATE,NAME(DIS1)"
/* "CONSOLE SYSCMD(#SQ VOL,9000,INV_TRKS) CART('MAINT')" */
"CONSOLE SYSCMD(D R,R) CART('maint')"
SAY "Return code = "RC
getcode = GETMSG('msg.','either','maint',,10)
SAY "GETMSG ended with "getcode
"CONSOLE DEACTIVATE"
Please help me fix this.
Thanks!