Home Forums WinForms controls Xceed Grid for WinForms How do I delete multiple rows Reply To: How do I delete multiple rows

User (Old forums)
Member
Post count: 23064

I figured it out:

For example you can catch the key down event for the delete key and then handle it diffently for normal DataRows or GroupManagerRows or whatever.

The code below is for deleting a group:

private void deleteGroup( GroupManagerRow row )
{

ReadOnlyDataRowList groupRows = row.ParentGroup.GetSortedDataRows(false);
for (int i= groupRows.Count-1; i>=0; i–)
{
groupRows[i].Remove();
}

}

Imported from legacy forums. Posted by sebastian (had 6761 views)