Home Forums WinForms controls Xceed Grid for WinForms Updating rows in a group Reply To: Updating rows in a group

User (Old forums)
Member
Post count: 23064

Try this (untested) code:<code>grid.DataRowTemplate.Cells[“alias”].LeavingEdit += new LeavingEditEventHandler(gridColumnAliasLeavingEdit);
private void gridColumnAliasLeavingEdit(object sender, LeavingEditEventArgs e) {
Cell cell = sender as Cell;
int columnIndex = cell.ParentColumn.Index;
CellRow row = cell.ParentRow;
GroupBase group = row.ParentGroup;
if (group != null)
foreach(DataRow dataRow in group.GetSortedDataRows(true))
if (dataRow != row)
dataRow.Cells[columnIndex].Value = e.NewValue;
}</code>

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