GoFiler Legato Script Reference
Legato v 1.5d Application v 5.25a
|
Table of Contents | < < Previous | Next >> |
Chapter Five — General Functions (continued)
Overview
The GetStringFromQuotes function retrieves a string (filename) from a quoted string or from a command line style string.
Syntax/Parameters
Syntax
string = GetStringFromQuotes ( string data, [boolean parse] );
Parameters
source
A string from which to get a string segment.
parse
An optional boolean value indicating that the function is parsing items. The default value is FALSE. See Remarks below.
Return Value
Returns a string containing the segment of source or an empty string on failure. If the data is not quoted, it is simply returned as is. Use the GetLastError function to retrieve error information.
On success and if the parse flag is set, the last error code will contain the next non-space item or last position in the source string.
Remarks
The GetStringFromQuotes function is principally designed for processing filename parameters either from command-line data or from dialog boxes. For example, if a filename is copied from explorer and pasted into a dialog control, it will be surrounded by quotes. This function will remove the surrounding quotes, if present.
The quote character is specifically code 0x22 or 34. Escape characters are not allowed, therefore a quote is not allowed in the string (a quote is not allowed in a filename).
The resulting string cannot be larger than 512 characters.
Leading spaces are always trimmed prior to detecting the quote. When in command line mode, parse parameter set to TRUE, and a quote is not present, the data is copied until a space (0x20) is encountered.
Related Functions
Platform Support
Go13, Go16, GoFiler Complete, GoFiler Corporate, GoFiler, GoFiler Lite, GoXBRL
Legato IDE, Legato Basic
Table of Contents | < < Previous | Next >> |
© 2012-2024 Novaworks, LLC. All rights reserved worldwide. Unauthorized use, duplication or transmission prohibited by law. Portions of the software are protected by US Patents 10,095,672, 10,706,221 and 11,210,456. GoFiler™ and Legato™ are trademarks of Novaworks, LLC. EDGAR® is a federally registered trademark of the U.S. Securities and Exchange Commission. Novaworks is not affiliated with or approved by the U.S. Securities and Exchange Commission. All other trademarks are property of their respective owners. Use of the features specified in this language are subject to terms, conditions and limitations of the Software License Agreement.