Hi,
With the grid, it's not that simple.
You can intercept the Enter keystroke by inheriting from the grid and
overriding the following methods:
ProcessCmdKey
ProcessKeyPreview
ProcessDialogKey
The first one might me unnecessary to override, I might have used it to
catch only some very grid-specific keystrokes like the Del key.
"Gidi" <an*******@discussions.microsoft.com> wrote in message
news:AE**********************************@microsof t.com...
i want the enter key press wll be an event.
this is my eventhandler header:
this.dataGrid1.KeyPress+=new
System.Windows.Forms.KeyPressEventHandler(this.dat aGrid1_KeyPress); is it ok?
and how do i write the method, the datagrid doesn't react when i press any
key (i tried to debug and i saw that nothing happens when i press any key)
i read the link that i got from here but it didn't help me to understand
how to do it... thnak you