General information
Title:
How to handle keypress event in datagridview cell
hi all
i am trying to handle keypress event but i am not getting result like after press enter key
Private Sub dataGridView_EditingControlShowing(ByVal sender As Object, ByVal e As DataGridViewEditingControlShowingEventArgs) Handles DataGridView1.EditingControlShowing
AddHandler e.Control.KeyDown, AddressOf Control_KeyPress
End Sub
Private Sub Control_KeyPress(ByVal sender As Object, ByVal e As KeyEventArgs)
MsgBox(e.KeyCode)
'If e.KeyChar = Chr(13) Then
' 'If (Char.IsNumber(e.KeyChar)) Then
' MsgBox("OK")
' ' //your code here
'End If
End Sub
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only