كود يسمح لك بكتابة احرف فقط في التيكست بوكس ولا يمكنك من كتابة ارقام

   Private Sub TextBox1_KeyPress(sender As Object, e As KeyPressEventArgs) Handles TextBox1.KeyPress
Select Case e.KeyChar
Case "ء" To "ي", "A" To "z", ControlChars.Back, Chr(Keys.Space)
e.Handled = False
Case Else
e.Handled = True
End Select
End Sub

Leave a Reply

Your email address will not be published. Required fields are marked *