HP OpenVMS Systems

ask the wizard
Content starts here

DCL procedure and image exit?

» close window

The Question is:

I have an interactive image (a news reader) that must be run on an 80 column
 terminal.  I normally like to have my terminal width set to 132.  I've tried
 to create a DCL command procedure that will do a SET TERMINAL /WIDTH=80, RUN
 the interactive image, a
nd then SET TERMINAL /WIDTH=132.
So here's what I have:
When I run this command procedure, it set's the terminal width properly, loads
 the newsreader, and then immediatly closes it and sets my width back to 132.
My question is:
Is there a way to force a DCL command procedure to wait for an interactive
 image to exit before it continues?
Ed "mid-level DCL hacker" Davis

The Answer is :

  Excepting certain explicit command sequences such as SPAWN/NOWAIT,
  DCL is entirely synchronous and waits for the image to complete.
  DCL does not proceed until the image exits.
  Please ask whomever supports the image in question for assistance.
  You clearly believe this has to do with the terminal width, though
  the OpenVMS Wizard strongly suspects this is simply the image
  encountering an error or unexpected condition and (quickly) exiting.
  Most likely, the image is simply attempting to read from SYS$INPUT
  and is reading an EOF (generated from the $ command immediately
  following the image).  If the program is attempting to read input,
  you can embed the data directly into the command procedure, or you
  can temporarily redirect the input out of the command procedure:
    $ define/user sys$input sys$command
    $ run sys:news.exe
    $ ! next command
  Newsreader tools such as the Freeware MXRN tool can be run from DCL
  command mode, and might provide an alternative to this approach.

answer written or last revised on ( 18-DEC-2001 )

» close window