DataGrid Escape key problem

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • shravan

    DataGrid Escape key problem

    Hi,
    I have a extended Windows Forms Datagrid, I have custom
    column styles defined for it. The problem is when I am in
    the new row and pressing escape two times
    - First time it's cancelling cell changes
    - Second time it's cancelling row changes
    it's doing this for all rows except for first row,
    whenever I am calling escape twice for a newly added row
    it's deleting the row, but if for the first time I have
    created a new row (first row) in the grid and pressing
    escape twice is not deleting the row (Pressing escape
    first time is rolling back cell level changes, but second
    time it doesn't work). It's happening for any of my custom
    styles -> TextBox or Combo or DatePicker...
    The ProcessGridKey method when recieving {Escape} key
    is calling DataGrid.Edit method which is forcing the grid
    not to delete the first row.
    Anybody please help.

    Thanks in Advance,
    Shravan.
Working...