skip to main content

Library Routines : C$GETLASTFILENAME

C$GETLASTFILENAME
The C$GELASTFILENAME library routine is used to retrieve the last file name and path used in a I/O statement.
Syntax:
 CALL "C$GETLASTFILENAME" USING fileName 
Parameters:
Examples:
Example - Get the filename and path of the last file used on a I/O stmt along with the last I/O file operation
   call "c$getlastfilename" using fileName filePath
   call "c$getlastfileop"   using fileOp
   *> assuming the file error code was already moved to a general variable
   display message "Error code    : " fs-code   x"0d0a"
                   "I/O Operation : " fileOp    x"0d0a"
                   "On file       : " fileName  x"0d0a"
                   "File path     : " filePath. 

Copyright (c) 2017 Veryant
Contact us
Please share your comments on this manual or on any
Veryant product documentation with the email button at the top left