I have a grouping grid with a number of levels of grouping.
I''d like a way to remember which group items were orignally expanded prior to refreshing the grid completely and then searching for each of those expanded groups and auto expanding them for the user.
I add each grouping column to syncGrid.TableDescriptor.GroupedColumns but can''t find a way to enumerate through the gird in order to check group.IsExpanded - should I be looking at syncGrid.Table.TopLevelGroup.Groups?
ADAdministrator Syncfusion Team July 6, 2004 11:46 AM
you can loop through the groups by iterating through groupingGrid.Table.TopLevelGroup.Groups.
For each group that has IsExpanded = true you can get the Category and store it in an array.
Once you have reloaded the grid, you can then loop through that array of category keys and for each key do a find using groupingGrid.Table.TopLevelGroup.Groups.FindGroup(categoryKey). FindGroup returns an index that can be passed into groupingGrid.Table.TopLevelGroup.Groups[index]. With that group you could then set IsExpanded = true.