The use the TextBox_Validate event.
If the text fails validation (isn't what you want it to be], then just set the Cancel to True. This will keep the focus on the control. (Assumming that the next control in the Tab order has the CauseValidation property set to True):
Private Sub TextBox1_Validate(Cancel As Boolean)
If TextBox1.Text <> "abc" Then
Cancel = True
Exit Sub
End If
End Sub [/b][/i][/u]*******************************************************
General remarks:
If this post contains any suggestions for the use or distribution of code, components or files of any sort, it is still your responsibility to assure that you have the proper license and distribution rights to do so!