Difference between revisions of "FILENAME - Get the filename & extension, without the path (Reports & Settings Report Generator function)"

From Catalyst
Jump to: navigation, search
(Updated from revision control)
 
Line 24: Line 24:
 
Will return the file name and extension portion of the input text.
 
Will return the file name and extension portion of the input text.
  
[[Category:Reports & Parameters Report Generator functions]]
+
[[Category:Reports & Settings Report Generator functions]]

Latest revision as of 13:03, 22 September 2016

Syntax

$FILENAME{filepath}

Description

Given a string containing a file name with path information, will return just the file name and extension with drive letter and/or path stripped off.

Given 'c:\sx\cr$err.log' as input, would return just 'cr$err.log'.
Will also cope with "Unix" style paths, which contain "forward slashes" as opposed to "back slashes"; as well as taking, for example, 'c:cr$err.log' and returning just 'cr$err.log'.


Parameters

filepath
A text parameter that can not be omitted.
The path and filename of the file.

Returns

A text value. Will return the file name and extension portion of the input text.