Version

SelectionChanged Property (DataTreeClientEvents)

This event is fired, after a change in the selection occur.
Syntax
'Declaration
 
Public Property SelectionChanged As String
public string SelectionChanged {get; set;}
Example
WebDataTree1.ClientEvents.SelectionChanged = "WebDataTree_SelectionChanged"
WebDataTree1.ClientEvents.SelectionChanged = "WebDataTree_SelectionChanged";
// The client event 'SelectionChanged' takes two parameters sender and e
// sender  is the object which is raising the event
// e is the DataTreeSelectionEventArgs
function WebDataTree_SelectionChanged(sender, e) {
    //Get thre newly selected tree nodes array
    var newSelectedNodes = e.getNewSelectedNodes();

    //Gets the text of the node at index 0 in the array
    var nodeText = newSelectedNodes[0].get_text();

    window.status = "Newly Selected node :" + nodeText;

}
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also