Collection Management

Create Empty 2D Array

Activity allows to create an empty two-dimensional array.
Arrays are used to store multiple elements as a single variable. An array is the data structure that stores a fixed number of elements of the same data type. The type of data stored in the array has to be specified beforehand. You cannot change the size or type of an existing array after it has been created. The elements of an array are indexed, starting with index (0)(0) - the first rank denotes the number of row, and the second one defines number of column.

The following figure illustrates the two-dimensional array 3x4 divided into rows and columns.


Dragging the activity to flowchart opens an input window requiring you to select your array’s data type, followed by activity window itself. You can specify the size of the array (give the number of rows and columns) and give a name to the Array there (create a variable, type e.g. String[][] or Int32[][], it must match chosen Element Type).


Array elements can be accessed using an index - simply type array name followed by element's indices in brackets (arr2d(1)(2) addreses to the element of the array "hh" - illustration above).

Parameter NameParameter TypeIn/OutDescription
Alternative Scenario If FailedBooleanInputcheckbox; default is "on"
ColumnsInt32Inputnumber of columns of the array
Display NameLiteralInputyou can change the name of activity for greater clarity of the scenario
Element TypeDropdownInputchoose the array's type from a dropdown list
Exclude from Transaction CheckBooleanInputcheckbox; default is "off"
RowsInt32Inputnumber of rows of the array
ArrayLiteralOutputname of the array
ResultBooleanOutputreturns the Boolean value: it will return True if no error is in activity, otherwise it will return False
Result CodeInt32OutputResult Code will return 0 if there is no error in activity, otherwise in most cases it will return 1, the extended result code will show only in several chosen activities

Last edited: 2023, 03 July.