![]()  | 
CSplitpath:GetExt2
The GetExt2 method returns the file extension from a CSplitpath object. The extension is returned without a preceding period, in a format like "fts". To return the path with a preceding dot character, use GetExt instead.
| 
 sExt = CSplitpath:GetExt2()  | 
 
  | 
    On
success, this method returns a string containing the file extension
without a preceding period.
    On
failure, this method returns nil.
Suppose a file exists with a full path named sPath. The following script retrieves the file extension:
| 
 | 
 -- create a CSplitpath object  | 
| 
 | 
 -- Specify the path to be split  | 
| 
 | 
 -- assigns the file extension component to the string sExt.  | 
| 
 | 
 -- when done with S, remove it from memory  | 
Mira Pro x64 Script User's Guide, v.8.73 Copyright Ⓒ 2024
Mirametrics, Inc. All Rights Reserved.