Custome Tree View Node crashes on .Clone()

Posted on 2006-04-25
Last Modified: 2008-02-01

I have a 2003 app,

On SortNode.clone the app throws this exception :

System.MissingMethodException - No parameterless constructor defined for this object.

SortNode is a custom control which inherits System.Windows.Forms.TreeNode, nothing fancy in it just a load of extra integer properties specific to the app.

Im totally lost on how to get this to work; do I need to create an override constructor? if so how as iv never done this before,


Question by:Ajfy2k
    LVL 96

    Accepted Solution

    Do you have a Sub New (default constructor)?

    LVL 1

    Author Comment

    Ye below is the sub new of  my custom control,

       Public Sub New(ByVal strText As String)
            Me.Text = strText
        End Sub

    this the problem?

    LVL 1

    Author Comment

    Sorted, added additional sub new of

        Public Sub New()

        End Sub

    And it now works,



    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    Suggested Solutions

    A while ago, I was working on a Windows Forms application and I needed a special label control with reflection (glass) effect to show some titles in a stylish way. I've always enjoyed working with graphics, but it's never too clever to re-invent …
    Introduction When many people think of the WebBrowser ( control, they immediately think of a control which allows the viewing and navigation of web pages. While this is true, it's a…
    Need more eyes on your posted question? Go ahead and follow the quick steps in this video to learn how to Request Attention to your question. *Log into your Experts Exchange account *Find the question you want to Request Attention for *Go to the e…
    Here's a very brief overview of the methods PRTG Network Monitor ( offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

    755 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now