Promotic
WikipediaLinkedInYoutubeTwitterFacebook

GetArray - method of object PmDataTable

Description:
Creating an array of values (of the Array type) from selected data items of the object.
Syntax:
GetArray(sType As String, index As Variant) As Array
Calling:
array = oDataTable.GetArray(sType, index)
Parameters:
sType(String) Type of selected values in the table:
"Row" - One row of the table is selected (i.e. 1-dimensional array is created). The index value must be an integer.

index>=0 means the index of the selected row (zero-based index).

index=-2 means the last row.

"Col" - One column of the table is selected (i.e. 1-dimensional array is created). The index value must be a String type or an integer.

If it is the String, then it is the column name.

If it is the integer, then index>=0 means the index of the selected column (zero-based index), index=-2 means the last column.

"All" - All table is selected (i.e. 2-dimensional matrix is created). The index value must be set to the value Empty.
index(Variant) Index to the table whose meaning is defined by the sType parameter
Example:
1-dimensional array containing values from the second row is assigned into the arr:
arr = oDataTable.GetArray("Row", 1)
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice