I have two webdatatree which are binded to different sqldatasources. When I drag and drop any node I want the database (Tables) to be updated accordingly. Can someone tell me any server-side event to implement this functionality.
Thanks,
Megha
Hello Megha,
you could use NodeDropped event. Please check out WebDataTree online samples: Drag and Drop Server Events and Drag and Drop Client Events
Please let me know if you have any further questions
Thanks for the reply. I have one more question regarding WebDataTree.
I have two webdatatrees, and they are populated with the same data initially. I can drag any item from webdatatree1 and drop it to the webdatatree2 , so the levels of any node in webdatatree2 can be changed. There might be a case where a new level is added to a node. Can someone suggest an efficient way to bind webdatatree so that it reflects all the dynamic changes made.The sql table I am using to generate webdatatree is :
Level_ID Parent_ID Child_ID
0 A B
1 B C
2 C D
1 E F
1 G H
2 H I
3 I J
Hello mmegha,
Is this a self-reference table? I would suggest you to use WebHierarchicalDataSource with self-reference data. Handle NodeDropped event and change the parent for the dragged node.
http://news.infragistics.com/forums/p/58654/299147.aspx
I used webhierarchicaldatasource with self reference data but I am not getting the desired results. For the data I copied earlier, I want level 0 at root level then level 1 children then level 2 children. The rows with new levels can be added to the tree and also the existing rows can be deleted. Can you please provide a code how to bind it on the server side so that I can get all the levels of a tree. These levels are not static for example: the levels at 5 currently has no children but if I drop a node there then the next time the tree is loaded it should show a child at level 6. Please help I need the code urgently.