جرب هذه الاكواد في حدث الفورم
Private Sub TextBox2_KeyPress(ByVal KeyAscii As MSForms.ReturnInteger)
If TextBox1.Value = "" Then TextBox1.SetFocus
End Sub
Private Sub UserForm_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
If TextBox1.Value = "" Then TextBox1.SetFocus
End Sub
Private Sub UserForm_MouseMove(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
If TextBox1.Value = "" Then TextBox1.SetFocus
End Sub
Private Sub UserForm_MouseUp(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
If TextBox1.Value = "" Then TextBox1.SetFocus
End Sub