I would check the status of the TSO profile PROMPT variable. When prompt is
ON (PROF PROMPT), the command will read the stack. If PROD NOPMROMT is set,
it will not. may be this is your case. Clist controls that with PROMPT
DATA-ENDDATA pair.

ITschak

ITschak Mugzach
Z/OS, ISV Products and Application Security & Risk Assessments Professional

On Wed, May 6, 2015 at 9:09 PM, J O Skip Robinson <[email protected]>
wrote:

> Sorry for not making the issue clear. SPACE was likely written elsewhere
> long ago but modified here over the years. The problem is not how to trap
> output. It uses PUTLINE, so both REXX OUTTRAP and CLIST &SYSOUTTRAP work
> fine. The problem is 'subcommand mode'. Some standard IBM command
> processors work this way: OPER and TEST for example. You enter the command,
> then enter various subcommands until you're done, then type END. The PDS
> command runs in subcommand mode.
>
> I cannot get a REXX to work in subcommand mode. For example,
>
> x = OUTTRAP("cmdl.")
>
> QUEUE Vxxxxx
> QUEUE END
> SPACE
>
> In REXX, the SPACE command is entered but does not read from the stack. It
> just sits and waits forever for terminal input. Whatever is entered breaks
> the process. The corresponding CLIST works fine.
>
> SET &SYSOUTTRAP = 1000
> SPACE
> V&VOL_SER_PREFIX
> SET l = &SYSOUTLINE
> SET &SYSOUTTRAP = 0
> SET i = 1
>
> DO WHILE &i <= &l
>   SET line = &STR(&&SYSOUTLINE&i)
>   ...
> ENDO
>
> Of course I could rewrite SPACE to work differently, but I'm asking
> whether there is a REXX solution to handle subcommand mode.
>
> .
> .
> .
> J.O.Skip Robinson
> Southern California Edison Company
> Electric Dragon Team Paddler
> SHARE MVS Program Co-Manager
> 626-302-7535 Office
> 323-715-0595 Mobile
> [email protected]
>
> -----Original Message-----
> From: IBM Mainframe Discussion List [mailto:[email protected]] On
> Behalf Of Lizette Koehler
> Sent: Wednesday, May 06, 2015 10:49 AM
> To: [email protected]
> Subject: Re: Did I really need a CLIST???
>
> Is this a SPACE command processor from cbttape.org or something home
> grown?
> Is SPACE using TPUTS/TGETS?  It might make this behavior understandable.
>
> I know with CLIST you can send an END command.  I will have to check out
> rexx.  You may wish to post on the TSO/REXX list.  They may have more ideas.
> Both CLIST and REXX discussed there.  Along with native TSO stuff.  ;-D
>
> Lizette
>
>
> > -----Original Message-----
> > From: IBM Mainframe Discussion List [mailto:[email protected]]
> > On Behalf Of J O Skip Robinson
> > Sent: Wednesday, May 06, 2015 9:48 AM
> > To: [email protected]
> > Subject: Did I really need a CLIST???
> >
> > Users needed a simple way to display percentage free space on a set of
> > DASD volumes identified by volser prefix. Simplest solution was to run
> > our own SPACE command, trap the output, do some calculations, and
> > display the answer. SPACE runs in subcommand mode, so issue SPACE
> > followed by subcommands to get desired output.
> >
> > I could not get this to work in REXX. As soon SPACE was entered, no
> > subcommands would be read from the stack until I manually entered 'end'.
> > That exited the SPACE command and lost all further processing
> opportunity.
> >
> > So I wrote a CLIST-first brand new one decades. I had to read the
> > manual a lot, made many mistakes, but got it working because CLIST
> > handles subcommand mode just fine. Question: did I really need to do
> that?
>
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to [email protected] with the message: INFO IBM-MAIN
>

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to