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

TcxCustomTreeView.CustomSort(TTVCompare,Longint,Boolean) Method

Sorts nodes using the specified node comparison routine.

#Declaration

Delphi
function CustomSort(SortProc: TTVCompare; Data: Longint; ARecurse: Boolean = True): Boolean;

#Parameters

Name Type
SortProc TTVCompare
Data Longint
ARecurse Boolean

#Returns

Type
Boolean

#Remarks

The CustomSort method is used to perform node sorting using the comparison routine specified by the SortProc parameter. If nil is passed as the SortProc parameter, the method behaves like the AlphaSort method. Please refer to the TCustomTreeView.CustomSort method description for details on using the CustomSort method.

It is not recommended that you use the CustomSort method. Instead, call the AlphaSort method and handle the OnCompare event to specify the appropriate node comparison logic. If the OnCompare event is not handled, the AlphaSort method compares nodes by their captions (the Text property of TTreeNode objects representing nodes).

See Also