does anyone knows how to input letters and disable inputting an integer or number?... plsss help...tnx
lerkei
0
Light Poster
Recommended Answers
Jump to PostIf I understand you correctly, you have a text box and you only want to have letters in there, and not numbers.
How I would tackle the problem is to use the text1_change() and then get the last character that is entered and then use the isnumeric . If …
Jump to Postu just to handle keychar.
try this following code :Private Sub text1_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles text1.KeyPress If (Microsoft.VisualBasic.Asc(e.KeyChar) < 65) _ Or (Microsoft.VisualBasic.Asc(e.KeyChar) > 90) _ And (Microsoft.VisualBasic.Asc(e.KeyChar) < 97) _ Or (Microsoft.VisualBasic.Asc(e.KeyChar) > 122) Then 'space allowed If (Microsoft.VisualBasic.Asc(e.KeyChar) <> …
All 5 Replies
bushman_222
0
Junior Poster in Training
Jx_Man
987
Nearly a Senior Poster
Featured Poster
Jx_Man
987
Nearly a Senior Poster
Featured Poster
lerkei
0
Light Poster
akgs
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.