From:	MERC::"uunet!CRVAX.SRI.COM!RELAY-INFO-VAX"  7-SEP-1992 12:04  7-SEP-1992 12:04:00.00
To:	info-vax@kl.sri.com
CC:	
Subj:	Re: HLL equiv of DCL SHOW DISPLAY

In article <1992Sep5.002240.1@musctn.monsanto.com>, rewise@musctn.monsanto.com (Richard Wiseman - VAX/VMS CraftsPerson) writes:
>
> 	I'an in need of a routine or the system services that will allow
> me to extract the equiv. information as a SHOW DISPLAY disp_name
> does in dcl, only from a HLL.

I got this out of the CSC a while back.

-Bruce

/**********************************************************/
/* Program:  WSQIO.C                                      */
/* Purpose:  To show how to get display information.      */
/* Date   :  December 1991                                */
/* Note   :  This is undocumented and unsupported code    */
/**********************************************************/
#include stdio
#include iodef
#include descrip

#define IO$M_WS_DISPLAY         64
#define DECW$C_WS_DSP_NODE       1
#define DECW$C_WS_DSP_TRANSPORT  2
#define DECW$C_WS_DSP_SERVER     3
#define DECW$C_WS_DSP_SCREEN     4

main()
  {
    int status;
    short channel, iosb[4], retlen;
    char info[80];
    $DESCRIPTOR (device, "DECW$DISPLAY");

    status = sys$assign (&device, &channel, 0, 0);
    if (!(status & 1)) lib$stop(status);

    status = sys$qiow (0, channel, IO$_SENSEMODE | IO$M_WS_DISPLAY,
                       iosb, 0, 0, info, sizeof(info) - 1,
                       DECW$C_WS_DSP_NODE, 0, 0, 0);
    if (!(status & 1)) lib$stop(status);
    if (!(iosb[0] & 1)) lib$stop(iosb[0]);

    info[iosb[2]] = '\0';
    printf ("The node name is:  %s\n",info);
  }

-- 
Bruce Tanner        (310) 860-2451 x 596    Tanner@Cerritos.EDU
Cerritos College    Norwalk, CA             DoD #0161  NOMAD #007

