length_text_array

This function calculates the length of an array of type TEXT. The length of an array is either the array length in the initial declaration of the array or, if the array has more elements than specified in the initial declaration, the actual number of elements in the array.

length_text_array ( input_array )

The result of this function is of type NUMBER; the number of elements in the input_array.

The function has one parameter:

  1. input_array, type TEXT; the array whose length will be determined.

Example

ARRAY TEXT test_array [1] 
ASSIGN test_array [1] := "This is the first value"
ASSIGN test_array [2] := "This is the second value"
ASSIGN test_array [3] := "This is the third value"
ASSIGN test_array [4] := "This is the fourth value"
ASSIGN test_array [5] := "This is the fifth value"
NUMBER function_result

ASSIGN length_function_result := length_text_array (test_array)

#
@(function_result)
#

Referencing an array element of an array that has been filled beyond its initial length will result in the creation of that element. The element will be created with a default value: 0 for NUMBER, "" for TEXT and FALSE for BOOL For instance the test IF testing[1] THEN FI will result in the creation of element 1 in array testing.