RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TCustomListControl.GetItemIndex Method

Returns the value of the ItemIndex property.

Pascal
function GetItemIndex: Integer; virtual; abstract;
C++
virtual __fastcall int GetItemIndex() = 0;

Override GetItemIndex to provide the read implementation for the ItemIndex property. GetItemIndex returns the index of the selected item, where the first item in the list has index 0, the second item has index 1, and so on. If no item is selected, GetItemIndex returns -1. If the list control supports multiple selected items, GetItemIndex returns the index of the selected item that has focus. 

 

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