Jump to page titleUNITED STATES
hp.com home products and services support and drivers solutions how to buy
» contact hp

:

more options
 

hp.com home
End of Jump to page title
Example-PL/I V2.2: Use of $QIOW To Output Data To A Terminal
Jump to content



» 

business support center

Home & Home Office Support:
» HP branded products
» Presario branded products
» Services & Warranties
Small & Medium Business Support:
» Small & Medium Business products
» Small & Medium Business services
Support for IT Professionals:
» Enterprise products (IT Resource Center)
» NonStop enterprise products
» Business & IT Services
Content starts here
Copyright (c) Digital Equipment Corporation 1985. All rights reserved

OVERVIEW:

This example will demonstrate the use of $ASSIGN and $QIOW system
services.  The $QIOW will output a character string to the terminal.

CAUTION:  This sample program has been tested using PL/I V2.2 on
VAX/VMS V4.1.  However, we cannot guarantee its effectiveness because
of the possibility of error in transmitting or implementing it.  It is
meant to be used as a template for writing your own program, and it may
require modification for use on your system.


PROGRAM EXAMPLE:

QIOW:   PROCEDURE OPTIONS(MAIN);

        %INCLUDE SYS$ASSIGN;
        %INCLUDE SYS$QIO;
        %INCLUDE $STSDEF;

        DCL CHAN        FIXED BIN(15);
        DCL IO$_WRITEVBLK GLOBALREF FIXED BIN(31) VALUE;
        DCL STRING      CHARACTER(44)
                        INIT('This tests an output string from $QIOW');
        DCL IOSB(4)     FIXED BIN(15);
        DCL DESCRIPTOR  BUILTIN;

/* Assign a Channel to the terminal.  The Logical TT should contain
   the terminal number */

        STS$VALUE = SYS$ASSIGN ('TT', CHAN, , );
        IF ^STS$SUCCESS THEN SIGNAL VAXCONDITION(STS$VALUE);

/* Output a character string using QIOW.  Note that the example is
   not using the Event Flag, AST, AST argument and P3 thru P6 arguments */

        STS$VALUE = SYS$QIOW( , CHAN,
                             IO$_WRITEVBLK,
                             IOSB,,,
                             STRING,
                             44,,,,);

        IF ^STS$SUCCESS THEN SIGNAL VAXCONDITION(STS$VALUE);

        END QIOW;





buy online or call 1.800.AT.COMPAQ
privacy statementusing this site means you accept its terms