Posted
on Jul 24, 2006
(permalink)
Hi,
I am using a client side javascript :
node.Collapse();
node.ExpandOnServer=2;
node.ExpandMode = ExpandMode.ServerSide;
node.Expand();
after this code, another ServerSideCallBack is triggered. On server, I get the node, but it has no chield on server, so chields are added on server, but when it comes to client all nodes that are added on server apperas on client with the old ones :) Thats why I have to delete the chields before this call. I could manage delete the HTML content under the node, but I could not really delete the chield nodes, I have to understand your javascript first to delete them.
It should not be so difficult. All we want is:
clientside:
node.DeleteChield(index) or
node.DeleteAllChields()
then
node.Refresh() is implemented as
node.DeleteAllChields()
node.ExpandOnServer=2
node.Expand()
another callback is triggered, new nodes are added and displayed on client correctly... Without this I cannot refresh the nodes. I cannot use serverside calls, or postback, or your ajaxpanel to do this, because tree is very large representing file system on server. All I do is refresh the whole page and display first nodes and wait for the next version, or find another product.
You should add clientside functions like:
node.MoveUp()
node.MoveDown()
node.DeleteChiled(index)
node.DeleteAllChileds()
node.Hide()
node.Add(newNode)
etc.
because for large trees we cannot use any serverside events...
Thanks...