Home Forums WinForms controls Xceed Grid for WinForms How to restore groupings Reply To: How to restore groupings

User (Old forums)
Member
Post count: 23064

<code>grid.BeginInit();
grid.GroupTemplates.Clear();
AddGroup(grid.Columns[“groupColumn1”]);
AddGroup(grid.Columns[“groupColumn2”]);
grid.EndInit();
void AddGroup(Column c) {
Group g = new Group();
g.GroupBy = c;
g.HeaderRows.Add(new GroupManagerRow());
grid.GroupTemplates.Add(g);
}</code>

Imported from legacy forums. Posted by Tommy (had 202 views)