BaseListBoxControl.GetItemValue(Int32) Method

Gets the specified item's value.

Namespace: DevExpress.XtraEditors

Assembly: DevExpress.XtraEditors.v20.1.dll


public object GetItemValue(
    int index
Public Function GetItemValue(
    index As Integer
) As Object


Name Type Description
index Int32

An integer value representing the zero-based index of the item whose value is returned.


Type Description

An object representing the specifyed item's value. null (Nothing in Visual Basic) if no item is found.


When no data source is bound to a control, this method returns the value of the item whose index is specified by the parameter. Otherwise, an object representing the contents of the data source field whose name is specified by the BaseListBoxControl.ValueMember property is returned. If this property is not specified, the entire item (a record at the specified position within a data source) is returned.

If you need to get the value of a currently selected item, use the BaseListBoxControl.SelectedValue property. The item's display text can be obtained via the BaseListBoxControl.GetItemText method.

See Also