GoFiler Legato Script Reference
Legato v 1.5d Application v 5.25a
|
Table of Contents | < < Previous | Next >> |
Chapter Five — General Functions (continued)
Overview
The Get32Word function retrieves a 32-bit dword or int from a buffer at a specified byte position.
Syntax/Parameters
Syntax
dword = Get32Word ( buffer data, int position, [boolean swap] );
Parameters
data
A buffer as bytes, chars, string or a handle to a Data Object. This is referenced on a byte by byte position to read two bytes that will create the 32-bit word.
position
An int specifying a zero-based position in bytes. This should point to the start of the data for the word. If the position plus the size of the data element is outside of the scope of the buffer, a range error will be returned.
swap
An optional boolean specifying whether or not to swap the incoming data by treating it as big-endian. By default, the data is treated as Intel little-endian (FALSE).
Return Value
Returns a dword comprised of the data read or 0 on failure. Use the GetLastError function to retrieve error information.
Remarks
The Get32Word function allows a script to reach into a buffer, access a specific section of bytes, and read it into an unsigned word. It is up to the programmer to extend the sign as required. Use the GetLastError, IsError or IsNotError function to differentiate between a return value of 0 and an error.
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.