UShort

See Also: Declaring Variables, Variable Declaration Commands, Struct, Short

Purpose

Declares one or more UShort (two byte unsigned integer) variables.

Syntax

To declare UShort variables

UShort {identifier} [… {identifier}]

Where

To declare array variables of type UShort

UShort{dimension-list} {identifier} […{identifier}]

Where

What It Does

The UShort command declares 2 byte unsigned integer variables in the range 0 to 65,535.

Multiple variables may be declared on one command line, with their names separated from each other by spaces.

Examples

Procedure DoTest

    UShort usMyVar

 

    Move 1 To usMyVar

End_Procedure

This example declares a UShort variable named usMyVar and initializes it.

 

UShort[] usSeats

This example declares 1 dynamic array variable, named usSeats, containing an undefined number of elements of type UShort.

UShort[5] usSeats

This example declares 1 static array variable, named usSeats, containing 5 of elements of type UShort.

UShort[][3] usSeats

This example creates a two-dimensional dynamic array variable named usSeats, containing an undefined number of elements of type UShort. Conceptually, this represents a rectangular array with an undefined number of rows, each of 3 columns.

You can declare dynamic multi-dimensional arrays where all dimensions are dynamic; these are called jagged arrays.

 

Notes