We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Adding custom controls dynamically in treeviewadv

Thread ID:





81945 May 25,2009 12:57 PM UTC May 26,2009 06:11 AM UTC WinForms 1
Tags: Tools
Administrator [Syncfusion]
Asked On May 25, 2009 12:57 PM UTC

How do I add custom controls as child node in treeviewadv?
I tried the following code :

Syncfusion.Windows.Forms.Grid.GridControl gridControl1=new Syncfusion.Windows.Forms.Grid.GridControl();
gridControl1[2, 1].Text = "2007";
gridControl1[2, 2].Text = "107,449,525";
gridControl1[2, 3].Text = "1,972,550(sq km) 761,602(sq mi)";

TreeNodeAdv treeNodeAdv8 = new Syncfusion.Windows.Forms.Tools.TreeNodeAdv();
treeNodeAdv8.ChildStyle.EnsureDefaultOptionedChild = true;
treeNodeAdv8.CustomControl = gridControl1;
treeNodeAdv8.EnsureDefaultOptionedChild = true;
treeNodeAdv8.Height = 56;
treeNodeAdv8.Optioned = true;

I get the grid along with the text "TreeNodeAdv" on the side. How do I only get the grid and not the text?

Poly J [Syncfusion]
Replied On May 26, 2009 06:11 AM UTC


Thanks for your interest in Syncfusion Products.
Set the text property of the treenodeAdv to an empty string for hide the text label in the tree node. Please use the below code snippet for set the text property of the treenode.

treeNodeAdv8.Text = "";

Let us know if you need further assistance with this.

Best Regards,


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon