[comp.os.vms] RTL TRNLNM

RSD1901@TAMSIGMA.BITNET (Shane Davis) (01/09/88)

Jonathan Edwards writes:

>Friends, Countrymen, and Vaxers of the highest esteem:
>
>I am writing a Pascal program which needs to translate a logical name.
>Looking through the RTL manual I see that there is a LIB$GET_SYMBOL,
>but nothing to translate logical names.  I know I could use $TRNLNM,
>but would prefer a simpler way.  Does anyone know why there is no
>LIB$GET_LOGICAL, or have I not found it?

There is no easier way using RTL routines per se. There is an RTL,
LIB$SYS_TRNLOG, but it works in an almost identical manner to SYS$TRNLNM; it
just lacks a few of the more detailed parameters. It, like SYS$TRNLNM,
requires use of DSC$ string descriptors, which is not a terribly difficult
task in Pascal. I'm not sure what file must be included in your Pascal program
to have use of these symbols, but it should reside in SYS$LIBRARY under a name
something like "DESCRIP.PAS" (if you're running a VAXcluster it will be in
the SYS$COMMON:[SYSLIB] library if Pascal is installed on all the nodes).

Alternatively, you could, I believe, use LIB$SPAWN to do a "$ SHOW
LOGICAL/OUTPUT=file.ext" command and then have your Pascal program read the
"file.ext" and find the translation there.

Good luck,

--Shane Davis
  Texas A&M Univ. CSC XPrint programmer

BITnet:  XPMAINT@TAMVENUS               TEXnet:  THOR::XPMAINT
         RSD1901@TAMSIGMA                        ZAC::RSD1901
         X222SD@TAMVM1