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. Image for the cookie policy date

GridGroupControl Relations

Hi, How do I add relationships between classes programatically. Let me explain: I have custom datasources (they also implement ITypedList), these sources are related-so I would wan''t a parent source and display its related child sources. I am trying to set these relations up but nothing is working. There are no relations in the TableDescriptor.Relations property is empty. The parent table displays perfectly - with custom controls etc... I just can''t add the relations... Please help Thanks Theo C

4 Replies

AD Administrator Syncfusion Team February 1, 2005 09:12 AM UTC

Take a look at the Syncfusion\Essential Suite\3.0.1.0\Windows\Grid.Windows\Samples\Grouping\StrongTypedCollection sample. I think you will need to create a GridRelationDescriptorCollection, and add your relations to it, and then set this collection as the TableDescriptor.Relations value.


TH TheoC February 1, 2005 09:25 AM UTC

Thanks Clay,


TH TheoC February 1, 2005 09:28 AM UTC

Thanks Clay, How do I go about setting up a RelationDescriptor. There are a lot of settings and I can''t find the right ones to get it to work. How do I get the related Custom DataSource into the ggc and then set the relation up between this child source and the parent source? Thanks for the help, Theo C


AD Administrator Syncfusion Team February 1, 2005 09:56 AM UTC

It sounds like you need to set the RelationKind to RelatedMasterDetails. Take a look at the Syncfusion\Essential Suite\3.0.1.0\Windows\Grid.Windows\Samples\Grouping\ManualRelations sample. Its sets up RelationKind.RelatedMasterDetails relations.

Loader.
Live Chat Icon For mobile
Up arrow icon