Hi,
I want keypress event sample code.. I have a textbox and I want only numbers to be allowed inside the textbox.. help me out plz..thanks in advance.
I tried:
Private Sub Text1_KeyPress(KeyAscii As Integer)
If (58 > KeyAscii > 47) Then
Else
MsgBox "Enter only Numbers"
Text1.Text = ""
End If
End Sub
But this din’t work.. plz help me out