Introduction
Introduction
This article explains simple ways to validate user input in a text box.
Here is the code; let's say we have two textboxes named txt1 and txt2 and two
buttons btn1 and btn2. Add the code given below:
Collapse
Private Sub btn1_Click(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles btn1.Click
txt1.Clear()
txt1.Focus()
End Sub
txt2.Clear()
txt2.Focus()
End Sub