HP OpenVMS Systemsask the wizard |
The Question is: How can I know the path of my DCL command procedure from inside of it? The Answer is :
F$ENVIRONMENT("PROCEDURE") will return the filespec of the currently
executing procedure. This can then be parsed to determine the device
and directory:
$ ThisFile=F$ENVIRONMENT("PROCEDURE")
$ ThisDev=F$PARSE(ThisFile,,,"DEVICE")
$ ThisDir=F$PARSE(ThisFile,,,"DIRECTORY")
|