


C$FULLNAME locates a file by using the runtime's filename translation and search logic. The routine returns the full name of the corresponding file.
Usage
CALL "C$FULLNAME" USING FILE-NAME, FULL-NAME, FILE-INFO GIVING STATUS-CODE
Parameters
FILE-NAME PIC X(n)
Specifies the name of the file to be located.
FULL-NAME PIC X(n)
Data item to receive the full name of the file.
FILE-INFO Group item (optional)
Group item to receive information about the file located. Must have this structure:
01 FILE-INFO.
02 FILE-SIZE PIC X(8) COMP-X.
02 FILE-DATE PIC 9(8) COMP-X.
02 FILE-TIME PIC 9(8) COMP-X.
The FILE-SIZE field is the size of the file in bytes. The FILE-DATE and FILE-TIME fields indicate the time the file was last modified. FILE-DATE has the form "YYYYMMDD" (year/month/day, note the 4-digit year) and FILE-TIME has the form "HHMMSShh" (hours/minutes/seconds/hundredths--just like ACCEPT FROM TIME). On all current implementations, the hundredths field is always set to zero.
STATUS-CODE Any numeric data item.
This receives the return status. It will be zero if successful, or "1" if FILE-NAME could not be found on disk or if FILE-NAME is not the name of a regular disk file.
Description
C$FULLNAME invokes the runtime's data file search logic on FILE-NAME. This involves using the configuration variables FILE-PREFIX, FILE-SUFFIX and FILE-CASE. The disk is searched using the rules described in section 2.8 of the User's Guide . The first matching file is returned in FULL-NAME. Note that the returned name is not automatically a full path name. Instead, it is the name of the file as the runtime found it. This may be based on the current directory.
If FILE-INFO is specified, information about the file located is returned in it.