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

Subclass TreeViewAdv

Thread ID:





88734 Aug 10,2009 01:34 PM UTC Aug 12,2009 02:02 PM UTC WinForms 1
Tags: Tools
Ole-Johan Ellingsen
Asked On August 10, 2009 01:34 PM UTC


I would like to create a subclass control, using TreeViewAdv as parent. I try "Add->User Control->Inherited User Control" and select the "Essential Studio\\Assemblies\3.5\Syncfusion.Tools.Windows.dll" file. I get a list of controls, but TreeViewAdv is not one of them. Any ideas?

Balavasanth [Syncfusion]
Replied On August 12, 2009 02:02 PM UTC

Hi Ole-Johan,

Thanks for your interests in Syncfusion products.

First I will try explaining you the basic difference between the User Control and the InheritedUserControls. Though the Inherited Controls and User Controls conceptually both can be grouped under Custom Controls category, but there is a difference between Inherited User Controls and User Controls in a practical implementation

Inherited User controls are those existing controls that you would inherit to add custom functionalities. E.g. Wizard, MonthCalendarAdv which typically inherits the System.Windows.Forms.UserControl(in the source) but you could see the implementation of this control as something like

public class CustomizationPanel : System.Windows.Forms.UserControl


the control which has the parent as System.Windows.Forms.UserControl are populated when you add the Tools.Windows assembly in the Inherited user control dialog. That is the reason the TreeView is not shown as it is not inherited from a user control. Usually these are used for common validations, GUI features etc.

Solution for your requirement:

If your requirement is to extent our controls with some common application logic. Make the modifiers public, protected, add some revalidations. You can make use of a UserControl or a custom class and inherit our control. I will explain a small scenario where I tried to extend the TreeViewAdv in the TreeViewAdvExt(a new control), use that object as a new control and try populating it. Kindly make use of the code snippet for more idea.

//Extended a new control keeping the TreeViewAdv as base.

public partial class TreeViewAdvExt : TreeViewAdv
public TreeViewAdvExt()

//implemented a new method to override the Vertical scrolling.

public void SetVScroll(bool value)
base.VScroll = value;

In my application.

//Created an instance of the new control.
treeviewadv1 = new TreeViewAdvExt();

//set its vertical scrolling to False.


Please find the below sample which explains the above.


We hope we are clear enough to your question. Please let us know still if you have any queries.



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