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

How to add child to Gridgrouping control

I am using Gridgrouping control.
I want to add child to a particular rowindex of gridgrouping control.
Please give me any solution for this issue.
Thanks and Regards,

1 Reply

MK Muthukumar Kalyanasundaram Syncfusion Team November 3, 2014 04:49 PM UTC

Hi Rasika,

Thank you for your interest in Syncfusion products.

If you want to add a child record to specific row in GridGroupingControl, you can use the “ChildTables.Add” method. The add method referred to the specific Key and Value to the dictionary. Please refer the below code,


  //The Parent list

            list = new BaseClassList();

            list.Add(new FirstClass(null, 0, "row0"));

            list.Add(new FirstClass(null, 1, "row1"));

            list.Add(new FirstClass(null, 2, "row2"));

            list.Add(new FirstClass(null, 3, "row3"));

            list.Add(new FirstClass(null, 4, "row4"));

            newList = list;

//First Child of List[3]  ( add child to specific row )

            list = new BaseClassList();

            list.Add(new FirstClass(newList[2], 0, "row4_childtable0_row0"));

            list.Add(new FirstClass(newList[2], 1, "row4_childtable0_row1"));

            list.Add(new FirstClass(newList[2], 2, "row4_childtable0_row2"));

            list.Add(new FirstClass(newList[2], 3, "row4_childtable0_row3"));

            list.Add(new FirstClass(newList[2], 4, "row4_childtable0_row4"));

            list.Add(new FirstClass(newList[2], 5, "row4_childtable0_row5"));

            newList[2].ChildTables.Add("List3_Child0", list);      ( add child to Row as 2 )

Please let us know if you have any concern.


Muthukumar K

Attachment: Parent_Child_relation_322c5a5b.zip

Live Chat Icon For mobile
Up arrow icon