SEC_TREECLASS::SetNodeParent
Changes the parent of an existing Node object.
Defined in: trcore.inl
Syntax
SetNodeParent( HTREEITEM hti, HTREEITEM htiNewParent, BOOL bInvalidate=TRUE, HTREEITEM hInsertAfter=TVI_LAST)
SetNodeParent( SECTreeNode *pNode, SECTreeNode *pNodeParent, BOOL bInvalidate=TRUE, HTREEITEM hInsertAfter=TVI_LAST)
Return Value
Returns TRUE if successful; otherwise 0.
Parameters
*pNode
A pointer to the node to re-parent.
*pNodeParent
A pointer to the new parent.
bInvalidate
If TRUE the control will be redrawn after re-parenting. Otherwise you must handle invalidating the control yourself. Default is TRUE.
hInsertAfter
Specifies where under the new parent the node should be inserted. Default is TVI_LAST.
Comments
Call this function to re-parent a tree node. This can be used effectively as a move operator for drag and drop. All children of the node being reparented will be moved as well, recursing until all child levels are moved. TRUE*/, HTREEITEM hInsertAfter /*TVI_LAST*/)