|
-
Apr 14th, 2006, 10:21 AM
#1
Hyperactive Member
Re: text box
there are lo of ways. Look in the ASC CODE CHART inside VB help to see the character's number.
And just put in the keypress event:
Select Case KeyAscii
Case 1 to 10, 15 to 20
KeyAscii = 0
MsgBox "TYPE ANOTHER CHAR!"
Exit Sub
End select
Of course instead of (1 to 10, 15 to 20) use all the chars you would like to filter.
About the other just use:
If InStr(1,Text1,"@") = 0 then msgbox "Please enter an @ in your textbox"
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|