RadGridView WinForms Self-referencing Hirarchy .NET 8

1 Answer 66 Views
GridView
Holger
Top achievements
Rank 1
Holger asked on 15 Nov 2024, 02:46 PM

I have a self-referencing Hierarchy working fine in .NET Framework 4.8,
now I upgraded to .NET 8 with

UI.for.WinForms.AllControls.Net60   2022.2.808-hotfix


public partial class Form1 : Form
{
    private Person[] _people = {
        new Person() { ID=1, Parent =0, Name = "Hans"},
        new Person() { ID=2, Parent =1, Name = "Fred"},
        new Person() { ID=3, Parent =1, Name = "Mary"},
        new Person() { ID=4, Parent =0, Name = "John"}
    };


    public Form1()
    {
        InitializeComponent();

        radGridView1.Relations.AddSelfReference(radGridView1.MasterTemplate, nameof(Person.ID), nameof(Person.Parent));
        radGridView1.DataSource = _people;
    }
}


public class Person
{
    public int ID { get; set; }
    public int Parent { get; set; }
    public string Name { get; set; }
}

Now, there are errors produced like "enumeration already finished".
Without this AddSelfReference, everything is fine. (just without the collapsable sections)
Setting DataSource first, doesn't make a difference either.

Something must have changed from the 4.8 to your 6.0 version.

1 Answer, 1 is accepted

Sort by
0
Nadya | Tech Support Engineer
Telerik team
answered on 18 Nov 2024, 11:27 AM

Hello, Holger,

I have tested with this specific version 2022.2.808-hotfix and I was able to reproduce the error.

However, this seems to be fixed when using a later version. Is it possible for you to download a later version and see how it works? On my side, I am using the latest 2024.4.1113 version but as far as I tested locally any version from this year works correctly on my end. We always encourage our clients to use as latest version as possible to benefit from all the improvements that we have made so far.

I hope this information helps. Please let me know how things are going after upgrading to a newer version.

Regards,
Nadya | Tech Support Engineer
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Holger
Top achievements
Rank 1
commented on 22 Nov 2024, 12:18 PM

Thanks for the effort, at least I'm sure I didn't do anything wrong.

I'm not a current subscriber and just for this little gimmick, it's too expensive.
I will update when I got new clients with UI related projects needing Telerik.

Tags
GridView
Asked by
Holger
Top achievements
Rank 1
Answers by
Nadya | Tech Support Engineer
Telerik team
Share this question
or