ExtractFileName

Top  Previous  Next

function ExtractFileName(sFileName As String) As String

 

Returns the extracted filename of the absolute path+filename specified in sFileName.

 

The resulting string is equal to sFileName if sFileName contains no drive and directory parts.

 

Parameters

 

sFileName ... String expression. Filename with or without drive/folder.

 

Example:

Dim s

 

= ExtractFileName("e:\exp\template.txt")

' returns s = "template.text"




Translate document: