Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

TdxFastList.IndexOf(Pointer,TdxListDirection) Method

Searches the specified pointer within the ordered pointer list.

#Declaration

Delphi
function IndexOf(AItem: Pointer; ADirection: TdxListDirection = ldFromBeginning): Integer;

#Parameters

Name Type
AItem Pointer
ADirection TdxListDirection

#Returns

Type
Integer

#Remarks

Call this function and pass a pointer as the AItem parameter to search it within the ordered pointer list. The optional ADirection parameter allows you to reverse the default search direction, which can be useful if the list is sorted. If the list contains the specified pointer, the IndexOf function returns its index; otherwise, returns -1.

Note

The Remove and Extract functions call IndexOf internally to search the specified pointer.

See Also