Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 522
  • Last Modified:

Restrict characters in ASP.NET textbox

I have a textbox on an asp.net webform that i would like to restrict it so on certain characters can be entered.  I only want to allow a-z (upper and lower) and 0-9.  Can i do this with a validation control?
0
Mike_Stevens
Asked:
Mike_Stevens
1 Solution
 
whityumCommented:
RegEx one, use this as the expression:

[^a-z0-9]
0
 
Mike_StevensAuthor Commented:
thanks...that is exactly what i was looking for.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now