Hi,
I faced a problem while collapsing node on client side. Consider following example: There are 3 root nodes in the tree when I click on collapse button the below function executes but it only collapses the first expanded node. The below function is taken from the Rad examples only...
Secnario:
R1
C1R1
C2R2
R2
C1R2
C2R2
R3
C1R3
When I click on collapse button only first node collapses and tree looks like:
R1
R2
C1R2
C2R2
R3
C1R3
When I again click on collapse button second node collapses and tree looks like:
R1
R2
R3
C1R3
function Collapse()
{
//get the explorer tree
var explorerTree = $find("<%= rtvExplorer.ClientID %>");
//get the root node count
var nodeCount = explorerTree.get_nodes().get_count();
//loop through root node and collapse them
for (var loopCount=0; loopCount<nodeCount; loopCount++)
{
var node = explorerTree.get_nodes().getNode(loopCount);
alert("node text : " + node.get_text() + ", loopCount : " + loopCount + ", nodeCount : " + nodeCount);
node.set_expanded(false);
}//for
}//function [Collapse]
Has anyone came across with this situation and found the solution???
Thanks and Regards,
Jaimin