COBOL Manual for TNS/E Programs (H06.08+, J06.03+)

library-reference
is a mnemonic-name associated, in the SPECIAL-NAMES paragraph, with either ZCOBDLL or
some other object file containing an object copy of COBOLFILEINFO.
fd-name
is the COBOL name of the file in the FD entry.
error-code
is a numeric data item described as USAGE COMPUTATIONAL PICTURE 9999 (or S9999)or
USAGE NATIVE-2. The COBOLFILEINFO routine returns the last file system file-system error
code to this data item. The value returned is always positive.
The access mode (see Linkage Section (page 179)) of error-code must be STANDARD.
file-name
is a DISPLAY data item of at least 24 characters where the actual 24-byte internal file name is
returned. The internal form of the file name is three 8-character fields containing the three
portions of the file name, with trailing spaces inserted and with no period (.) separators.
If file-name is composed entirely of spaces or has an 8-character volume name, it cannot
be converted to internal form. To convert it to internal form, use the COBOL_FILE_INFO_ routine.
The access mode (see Linkage Section (page 179)) of file-name must be STANDARD.
file-number
is a numeric data item described as USAGE COMPUTATIONAL PICTURE S99. The
COBOLFILEINFO routine returns the file’s open number to this data item.
file-number has the value -1 in each of these cases:
The file is not open.
The file is OPTIONAL and not present (even if it is open).
After the file was opened, the I-O status code was “05, rather than “00” (see Nonexistent
Files).
The access mode (see Linkage Section (page 179)) of file-number must be STANDARD.
Usage Consideration: Do not use COBOLFILEINFO to obtain the operating environment error
number associated with the failure of any input-output operation that is performed simply with
COBOL input-output verbs (such as READ). The HP COBOL special register GUARDIAN-ERR was
650 Libraries and Utility Routines