Hi,
http://www.syncfusion.com/FAQ/WinFor...c44c.asp#q836q
Ken
--------------
"Nicola Baldi" <(E-Mail Removed)> wrote in message
news:0AF6797A-0A94-4A2C-B42A-(E-Mail Removed)...
> Hi!
> I've used the following code to intercept a KeyEvent into a DataGrid.
>
> ******************************************
> Private Sub DataGrid1_KeyDown(ByVal sender As Object, ByVal e As
System.Windows.Forms.KeyEventArgs) Handles DataGrid1.KeyDown
> ' Check if F2 Key is pressed.
> If e.KeyCode = Keys.F2 Then
> ' Key pressed, Show MsgBox
> MsgBox("F2 Key pressed!", MsgBoxStyle.Exclamation, "Ok, event
Intercepted")
> End If
> End Sub
> ******************************************
>
> When the cursor is into a cell of my DataGrid, the MsgBox doesn't appear.
If I select, by example, the caption text part of the DataGrid control and
then I press F2 Key, the event is intercepted and MsgBox appear!
>
> But I don't want it. I want intercept the event when the cursor is located
into a cell of my DataGrid!
> What should I do to intercept that event?
>
> Thanks in advance.
> ------------------------
> Nicola Baldi