| **Navigation:**  [[abc library reference.htm|ABC Library Reference]] > ASCIIFileClass > AsciiFileClass Methods >====== GetFilename (return the filename) {{c6h0009.jpg|C6H0009.jpg}} ====== | [[getdosfilename let end user select file .htm|{{btn_prev_n.gif|Previous page}}]][[abc library reference.htm|{{btn_home_n.gif|Return to chapter overview}}]][[getlastlineno return last line number .htm|{{btn_next_n.gif|Next page}}]] | | || **GetFilename** {{blk2blue.jpg|blk2blue.jpg}} The **GetFilename **method returns the name of the ASCII file. **Implementation:** The GetFileName method uses the [[name return file name .htm|NAME]] function. See the //Language Reference// for more information. **Return Data Type:     **STRING **Example:** ** INCLUDE('ABASCII.INC')                  !declare ASCIIViewerClass** **Viewer    AsciiViewerClass,THREAD        !declare Viewer object** **Filename  STRING(255),THREAD             !declare filename variable** **AsciiFile FILE,DRIVER('ASCII'),NAME(Filename),PRE(A1),THREAD** **RECORD     RECORD,PRE()** **Line        STRING(255)** **           END** **          END** ** CODE** ** !program code** ** MESSAGE('Filename:'&Viewer.GetFilename()) !get the ASCII filename**