GoFiler Legato Script Reference
Legato v 1.5d Application v 5.25a
|
Table of Contents | < < Previous | Next >> |
Chapter Five — General Functions (continued)
Overview
The StringToTimeZone function parses a standard time zone string and returns formatted information.
Syntax/Parameters
Syntax
dword = StringToTimeZone ( string data );
Parameters
data
A string in the form of a time zone appendage such as “+0500” or “z”.
Return Value
Returns a dword as formatted time zone information or returns a formatted error code. Formatted error codes will contain either ERROR_RANGE or ERROR_SYNTAX with an ORed subfield of 1, 2 or 3 depending on the location of the error.
Remarks
StringToTimeZone can be used to parse the zone information as part of a formatted email date or ISO-8601. Data is returned in the form of a word with the following bits set depending on the source data:
Value | Bitwise | Description | ||||
STTZ_MODE_MASK | 0xC000 | Mode Mask (Z + or -) | ||||
STTZ_UTC | 0x2000 | Specified as 'Z' or UTC | ||||
STTZ_PLUS | 0x4000 | Zone Offset Specified as '+' | ||||
STTZ_MINUS | 0xC000 | Zone Offset Specified as '-' | ||||
STTZ_MINUTES | 0x003F | Zone Number Minutes | ||||
STTZ_HOURS | 0x3F00 | Zone Number of Hours |
For example:
Source “+0500”
Results in:
0x00004500
As:
STTZ_PLUS for ‘+’
STTZ_HOURS masked as 0x500 or 5 hours
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.