I have a XamGrid, with a filtersettings set to display the filter row.
We have functionality in the grid mouse events to detect the delete key and to delete any selected rows. The problem is, if they are trying to remove the filter cell value by hitting the delete key while using the filter row, our logic is still being fired.
How would I tell whether they are in a regular grid row, or the filter row when the "DEL" key is pressed?
Darrell,
Thanks, I was using the KeyUp event for the grid. Their was no e.Row or e.Cell but I didn't know about RowType and it got me going in the right direction. I used the Grid's ActiveCell property.
// exit out if clicking delete key in filter rowif (igGrid.ActiveCell != null && igGrid.ActiveCell.Row.RowType == RowType.FilterRow) return;This appear to work for me.Thanks,Ken
Not being sure what event you are in,
Check to see if off the event args you have
e.Cell
or
e.Row
if you do then you can check the e.Cell.Row.RowType, which is an enum value. Data rows would have a different RowType value then other Rows,
RowType.DataRow