Visual Basic Extensibility Reference

Visual Studio 6.0

IndexedValue Property

See Also   Example   Applies To

Returns or sets a value in an indexed list or an array.


object.IndexedValue [index1, index2,][ index3,] [index4]][ = value]

The IndexedValue property syntax has these parts:

Part Description
object An object expression that evaluates to an object in the Applies To list.
indexn A numeric expression specifying index position. IndexedValue accepts up to four indices. The number of indices accepted by IndexedValue is the value for the same property returned by the NumIndices property.
value An expression that evaluates to a type acceptable to the control.


If the property is a list (as indicated by NumIndices), then IndexedValue returns the element of the list specified by the index parameters.

IndexedValue is used only if the value of the NumIndices property is greater than zero. Values in indexed lists, as in the List property of a ListBox control, are set or returned with a single index.