RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
System::OleVariant::OleVariant_for_arrays

Creates an System::OleVariant array:

Use the array constructors to create a Variant array. The first syntax creates an System::OleVariant array with the bounds given by bounds and the element type given by varType. The bounds parameter must contain an even number of values, and each pair of values specify the upper and lower bounds of one dimension of the array. The boundsSize parameter is the index of the last element in bounds. The element type of the array, given by the varType parameter, must be one of the TVarData type codes, and cannot include the varArray or varByRef bits. The element type cannot be varString. To create an array of strings, use the varOleStr type code. If the element type is varSystem::OleVariant, the elements of the array are themselves System::OleVariants and can, in turn, contain System::OleVariant arrays. 

The second syntax creates a one-dimensional System::OleVariant array with the elements given by the values parameter. The low bound of the returned array is zero, the high bound is given by valuesSize (the index of the last value). The element type of the instantiated array is System::OleVariant

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!