The TreeView_RemoveNode() function deletes the specified node from a tree view field.
TreeView_RemoveNode(tree_view_field, node_ID)
• tree_view_field – The tree view field containing the node to remove.
• node_ID – A long integer specifying the ID of the node to remove.
A boolean indicating whether the node was successfully removed. True indicates the node was successfully removed. False indicates the node was not removed.
When a node is removed, all of its children are removed as well. To remove all nodes from a tree, use the TreeView_RemoveChildren(), specifying the node TV_ROOT.