How to remove the grouped headers in WinForms GridGrouping?
After Grouping, when any change is made in the columns, that is, when expressions are added or columns are removed, then the modifications are not reflected in the GroupDropArea. You need to reset the Grouped Header collection so that the modification done in the columns can also be reflected in the GroupDropArea
You can use the GroupedColumns.Reset() method when the changes are done in the columns, to repopulate the Grouped Columns. In the following example, a column Id is grouped and then it is removed from the grid.
//Resets the Grouped Columns. this.gridGrouping.TableDescriptor.GroupedColumns.Reset();
‘Resets the Grouped Columns. Me.gridGrouping.TableDescriptor.GroupedColumns.Reset()
I hope you enjoyed learning how to remove the grouped headers in WinForms GridGrouping.
You can refer to WinForms GridGrouping feature tour page to know about its other groundbreaking feature representations and documentation, and how to quickly get started for configuration specifications. You can also explore our WinForms GridGrouping example to understand how to create and manipulate data.
If you have any queries or require clarifications, please let us know in the comments section below. You can also contact us through our support forums, Direct-Trac, or feedback portal. We are always happy to assist you!