CALL "C$RERRNAME" USING fileName  | 
fileName  | PIC X(n)  | Receives the full pathname of the latest file used by a COBOL I/O statement, followed by its logical name enclosed in parentheses.  | 
*> define crerr-status and rerrname as pic x(n) display-file-error.   call "C$RERR"     using crerr-status   call "C$RERRNAME" using rerrname   display message "Error " file-status crerr-status " on " rerrname   |