Creating an Array or Matrix (BDE)
In the Elements palette or toolbar, click the
Array or
Matrix button. The properties editor is opened. Since arrays and matrices are created as variables, the Non-Volatile attribute is deactivated.
In the Kind combo box, select Variable or Parameter.
Set the dimension(s) and the variant size(s) of the array or matrix.
In the X (and Y) fields, enter the maximum X (and Y) size of the element.
To specify a variant size, use the Variant Size field to select the system constants you want to use as dimension values.
Both normal and user-defined system constants can be used. The value of a system constant should be in the range 1 ... X (or 1 ... Y).
To specify a variable size, use the Variant Size field to select *.
The X (and Y) fields are disabled.
In the Basic Type combo box, assign the element type.
The basic scalar types and Enumeration and Record are available. If you select Enumeration or Record, the
following happens. Adjust the other element properties as described in Editing the Configuration of an Array or Matrix, then click OK.
If you exceeded the maximum size of the element axes in the Dimension fields, the following warning opens.
The possible max size has to be between 1 and 65535.
Please adjust your settings.If the product of the X and Y dimensions of a matrix exceeds the maximum size of the matrix, the following warning opens.
The possible matrix elements max size of 1048576 has been exceeded. Please adjust your setting <number>.
- Confirm the warning with OK and adapt the dimension(s).
If you selected a system constant whose value is outside the allowed range, the following warning opens:
The Attribute * Size (<n>) is not in the allowed range of >0 and max value (<i>)
- Place the element in the drawing area.
- If necessary, re-open the properties editor and adjust the size.
Note |
|---|
Creating an array or matrix of kind Message is described in Creating a Message. |
If you want to optimize the generated initialization code of arrays/matrices of scalar or enumeration type, activate the Generating Sparse Arrays target option. See also Initialization of Arrays and Matrices.
See also
Editing the Configuration of an Array or Matrix
Variant Size for Arrays and Matrices
Variable Size for Arrays and Matrices
Initialization of Arrays and Matrices
Constants and System Constants