Removes the specified node from the TreeView's Nodes collection.
Newlook Smartclient only.
App.ActiveForm.TreeViewControl.Nodes.Remove(Index)
Index – (Integer, Required)
The key of the node to be removed.
Returns a Boolean indicating the success or failure of the action.
If the node that is removed has children, then these nodes will be removed as well.
The following example will remove the node with the key "M2A" from the tree view control:
function RemoveNodeByKey()
{
//Remove the dynamically inserted node via its key
removeSuccess = App.ActiveForm.tvOrgChart.Nodes.Remove("M2A");
App.SetValue("RemoveSuccess", removeSuccess);
}
function RemoveClickedNode()
{
//Remove the last clicked node
vLastClickedNode = App.ActiveForm.tvOrgChart.LastClickedNode.Key;
removeSuccess = App.ActiveForm.tvOrgChart.Nodes.Remove(vLastClickedNode);
}
Sub RemoveNode
'Remove the specified node
App.ActiveForm.tvOrgChart.Nodes.Remove "M2A"
End Sub
Add Method - Nodes | Clear Method | RefreshForm method
© 2004-2021 looksoftware. All rights reserved.