Programming-With-Actuate-Basic.Pdf
Total Page:16
File Type:pdf, Size:1020Kb
Programming with Actuate Basic This documentation has been created for software version 11.0.5. It is also valid for subsequent software versions as long as no new document version is shipped with the product or is published at https://knowledge.opentext.com. Open Text Corporation 275 Frank Tompa Drive, Waterloo, Ontario, Canada, N2L 0A1 Tel: +1-519-888-7111 Toll Free Canada/USA: 1-800-499-6544 International: +800-4996-5440 Fax: +1-519-888-0677 Support: https://support.opentext.com For more information, visit https://www.opentext.com Copyright © 2017 Actuate. All Rights Reserved. Trademarks owned by Actuate “OpenText” is a trademark of Open Text. Disclaimer No Warranties and Limitation of Liability Every effort has been made to ensure the accuracy of the features and techniques presented in this publication. However, Open Text Corporation and its affiliates accept no responsibility and offer no warranty whether expressed or implied, for the accuracy of this publication. Document No. 170215-2-130331 February 15, 2017 Contents About Programming with Actuate Basic. .xi Part 1 Working with Actuate Basic Chapter 1 Introducing Actuate Basic . 3 About Actuate Basic . 4 Programming with Actuate Basic . 4 Understanding code elements . 5 About statements . 5 About expressions . 6 About operators . 7 Using an arithmetic operator . 7 Using a comparison operator . 8 Using logical operators . 8 Using the concatenation operator . 9 Adhering to coding conventions . 9 Commenting code . 10 Breaking up a long statement . 10 Adhering to naming rules . 10 Using the code examples . .11 Chapter 2 Understanding variables and data types . 13 About variables . 14 Declaring a variable . 14 Using a global variable . 15 Using a local variable . 16 About class variables . 16 Declaring an array . 16 About multidimensional arrays . 17 About dynamic arrays . 17 About functions used with an array . 18 About data types . 18 Using a standard data type . 18 Using an Actuate Foundation Class data type . 20 Assigning a data type . 20 Using the As keyword . 20 i Using a type-declaration character . .21 About enums . .21 About constants . .22 Working with Variant data . .23 About numeric Variant data . .24 About functions used for a Variant variable . .24 Working with String data . .24 Declaring a String . .25 Using binary string data . .25 Manipulating a string . .25 Formatting a string using Str or Str$ . .27 Formatting a string using Format or Format$ . .27 Comparing strings . .28 Changing the capitalization of a string . .28 Removing spaces from a string . .29 Embedding special characters in a string . .29 Embedding quotation marks in strings . .29 Embedding tabs and new-line characters in strings . .29 Working with numeric data . .30 About numerical data types . .30 About the Currency data type . .30 Converting a string to a number . .31 Working with date and time data . .31 Using date and time display formats . .31 Formatting date and time values . .32 Working with a user-defined data type . .33 Using an alias . .33 Using a structure . ..