TreeView_SortChildren macro
Sorts the child items of the specified parent item in a tree-view control. You can use this macro or send the TVM_SORTCHILDREN message explicitly.
Syntax
BOOL TreeView_SortChildren( HWND hwndTV, HTREEITEM hitem, BOOL fRecurse );
Parameters
- hwndTV
-
Type: HWND
Handle to the tree-view control.
- hitem
-
Type: HTREEITEM
Handle to the parent item whose child items are to be sorted.
- fRecurse
-
Type: BOOL
Value that specifies whether the sorting is recursive. Set fRecurse to TRUE to sort all levels of child items below the parent item. Otherwise, only the parent's immediate children are sorted.
Return value
Returns TRUE if successful, or FALSE otherwise.
Remarks
This message alphabetizes the tree items using lstrcmpi on the item name. You can use the TVM_SORTCHILDRENCB message to customize the ordering behavior.
Requirements
|
Minimum supported client |
Windows Vista [desktop apps only] |
|---|---|
|
Minimum supported server |
Windows Server 2003 [desktop apps only] |
|
Header |
|