|
-
Sep 1st, 2005, 08:37 AM
#1
Thread Starter
Fanatic Member
Validate textbox to be alpha only
Guys,
How can I force a textbox on an asp.net page to contain alpha and num chars only ? ie - No symbols.
When the users hit a button I am adding a record to my SQL dbase and I need to ensure they are not using symbols in certain fields.
Thanks
Bob
-
Sep 1st, 2005, 08:57 AM
#2
Hyperactive Member
Re: Validate textbox to be alpha only
Use a RegularExpressionValidator control.
-
Sep 1st, 2005, 09:52 AM
#3
Thread Starter
Fanatic Member
Re: Validate textbox to be alpha only
Thanks Glen, but what would the validation expression be ?
Thanks
Bob
-
Sep 1st, 2005, 10:16 AM
#4
Hyperactive Member
Re: Validate textbox to be alpha only
This may not be spot on but it shouldn't be far away.
[^a-zA-Z0-9]
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
|