Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted on Jun 29, 2007 19:49
open dhtmlx forum
How to make the Parent Id of all the tree element 0 by default ie right after loading the grid when the parent has no Child . Right now im getting a NULL value when i try to display the parentid of the selected item at the beginning ie when the tree datatype has no Child

How to make the Parent Id of all the tree element 0 by default i.e right after loading the grid . Right now i'm getting a NULL value when i try to display the parent id of the selected item at the beginning ie when the tree data type has no Child . To be more specific " When i create a grid after loadXML command i click on the column corresponding to the tree datatype. I issue a Right Click handler which displays the parent Id of the same (in this case NULL) using an alert message. But when i do mygrid.moveRowTo(mygrid.getSelectedId(),mygrid.getParentId(mygrid.getSelectedId()),"move","sibling"); command inorder to make the child a parent im getting the parent id of the Moved element as 0. this cuses problem in further steps during my Sort operation.

Kindly help me out
Answer posted on Jul 07, 2007 19:17
The current version of dhtmlxTreeGrid has not such entitiy as super root items, any value which equal to js logical null (null,"",0)  can be threated as super root item id. For now there is no way to force more strict behavior.

Oncoming version 1.4 will have more strict hierarchy and provide|recognize only ID==0, if necessary - please contact at dhtmlx@scand.com, I can send you the betta version code ( release planed on next week, so it is pretty stable )
Answer posted by Andrei (Support) on Dec 03, 2014 17:01

The information connected with java export excel and slider javascript also can help you, so please check it too.