Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
157
Adding Childnodes to ultraTree
posted

I am try to populate the treenodes dynamically from database so I am able to do that in treeview of VS 2005 but with Ultra tree its displayinge me just the parent nodes.what can be the reason?? and I switched to  ultratree because I will be displaying 4 columns as child nodes whcih can be modified (edit)....so how will I be able to do that I am a newbee....so please if possible explain me in detail .Thanks 

This code works for populating the child node for  a simple treeview  but not for ultratreeview

 

             TreeNode mainNode = new TreeNode();
            mainNode.Text = "Eserver";
            this.ultraTree1.Nodes.Add(mainNode.Text);
            foreach (DataRow row in Eset.Tables[0].Rows)
            {
                TreeNode newNode = new TreeNode();
                foreach (DataRow rowchild in row.GetChildRows("RelEntLic"))
                {
                    TreeNode childNode = new TreeNode();
                    childNode.Text = rowchild["YearsBack"].ToString();
                    childNode.Tag = rowchild["EntitlementSetID"];
                    newNode.Nodes.Add(childNode);
                }
                newNode.Text = row["FullDeatilsESet"].ToString();
                newNode.Tag = row["EntitlementSetID"];
                //newNode.SelectedImageIndex
                this.ultraTree1.Nodes[0].Nodes.Add(newNode.Text);
            }

Parents Reply Children
No Data