collapse nested child tables in GGC

Hi, In a GGC, I defined two tables nested below the top level. When user clicks the + sign to view details from top level record, I want the nested records to default to collapsed. How do I do this? Thanks, NJ

1 Reply

AD Administrator Syncfusion Team December 13, 2005 11:40 PM UTC

Try handling the RecordExpanded event and closing the tables at that point.
private void gridGroupingControl1_RecordExpanded(object sender, RecordEventArgs e)
{
	Record r = e.Record;
	if (r != null && r.NestedTables.Count > 1 )
	{
		r.NestedTables[0].IsExpanded = false;
		r.NestedTables[1].IsExpanded = false;
	}
}

Loader.
Up arrow icon