Self referencing tree

5 posts, 0 answers
  1. kris860911
    kris860911 avatar
    8 posts
    Member since:
    Jun 2007

    Posted 22 Oct 2007 Link to this post

    Hi.
    I am using the Rad Treeview for Win Forms.
    I am trying to bind the tree to a datatable.
    The table consists of columns that include ID and ParentID
    However, the ID and ParentID are GUID's. Am I correct in assuming that the columns need to be integers? As the binding is giving me weird errors (Unable to cast object of type 'System.Windows.Forms.RelatedPropertyManager' to type 'System.Windows.Forms.CurrencyManager'.)

    What do you suggest I do to fix this? Is my only option to go and create a method that will loop through each of these rows in my table and convert their GUID's into integers and match up the related ParentID's?

    Thanks for any help,
    Kris
  2. Jordan
    Admin
    Jordan avatar
    547 posts

    Posted 22 Oct 2007 Link to this post

    Hi Chris,

    Currently RadTreeView uses the string representation of the ID field of the bound records.
    This means that one can have integer IDs (which is the most common case).

    Judging by the error message you sent us, it seems that a CurrencyManager cannot be found using the given DataSource and DataMember. This most probably means the RadTreeView is bound to a data source that it does not support.

    It will be best if you open a support ticket and send us a sample project so we can investigate further.

    Thank you for your cooperation.

    Greetings,
    Jordan
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. UI for WinForms is Visual Studio 2017 Ready
  4. kris860911
    kris860911 avatar
    8 posts
    Member since:
    Jun 2007

    Posted 23 Oct 2007 Link to this post

    Hmm. That's alot of effort to create a new project with the datatable etc.
    All I want to know is:
     Does the Win Forms Treeview allow you to have the ID and Parent ID (In the self referencing mode) as Guids? ie: 682b61d0-fdb3-4c9f-8c0c-d511c80a1f07
  5. Jordan
    Admin
    Jordan avatar
    547 posts

    Posted 23 Oct 2007 Link to this post

    Hello Chris,

    The RadTreeView does currently not support Guids as IDs. We are planning to include this functionality in the upcoming Q2 SP2 release.

    For the time being, you could try mapping the Guids to integers before binding RadTreeView to the data.

    Thank you for your question. Contact us again, if we could be of further assistance.

    Regards,
    Jordan
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  6. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 21 Mar 2011 Link to this post

    Hello kris860911,

    I am glad to inform you that in Q1 2011 we have introduced a major upgrade of RadTreeView control, which is now virtualized and fully customizable. Feel free to download the latest release and try it out. For more information on our latest release refer to this blog post.
     
    Greetings,
    Stefan
    the Telerik team
Back to Top
UI for WinForms is Visual Studio 2017 Ready