Private Sub ComboBox2_KeyDown(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles TextBox8.KeyDown, TextBox6.KeyDown, TextBox5.KeyDown, TextBox3.KeyDown, TextBox2.KeyDown, DateTimePicker2.KeyDown, DateTimePicker1.KeyDown, ComboBox2.KeyDown If (e.KeyCode = Keys.Enter) Then End If if (Me .GetNextControl(ActiveControl, true) != null) e.Handled = True Me.GetNextControl(ActiveControl, True).Focus() End If
How to make Enter on a TextBox act as TAB button
VB.NET
!=
<>
null
Nothing
If object isNot Nothing then '... End If
If Me.GetNextControl(ActiveControl, True) IsNot Nothing Then
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)