The TreeView_GetParent() function returns the node ID of the parent of the specified node.
TreeView_GetParent(tree_view_field, node_ID)
• tree_view_field – The tree view field containing the specified node.
• node_ID – A long integer specifying the ID of the node whose parent will be returned.
A long integer containing the node ID of the parent of the specified node. If the specified node is a root-level node, the value TV_ROOT is returned.