Public Class Form1 Protected Overrides Function ProcessCmdKey(ByRef msg As Message, keyData As Keys) As Boolean Const WM_KEYDOWN As Integer = &H100 If msg.Msg = WM_KEYDOWN Then If msg.WParam = Keys.Enter Then Dim bit25 As Integer = &H1000000 Dim isTenkeyEnter As Boolean = CBool(msg.LParam.ToInt32 And bit25) If isTenkeyEnter Then SendKeys.Send(vbTab) Return True End If End If End If Return MyBase.ProcessCmdKey(msg, keyData) End Function End Class