Hi,
How To restrict Asp.Net TextBox to allow Only Capital letters and numbers...i.e(Alpha-Numeric)..??Asp.Net Textbox(AlphaNumeric)
3 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Riddhi ValechaRank #794 · 2.9K reputationPosted May 13, 2013, 10:17 PM EDT
Refer the following links-
http://geekswithblogs.net/mbcrump/archive/2010/06/27/textbox-validation-for-alphanumeric-chars.aspx
http://www.codeproject.com/Questions/260680/how-to-restrict-user-to-enter-only-numbers-in-text
http://codingresolved.com/discussion/41/how-to-restrict-textbox-to-numbertextbox-numbers-onlytextbox-just-numbers/p1
Hope this helps.
Mark as accepted answer if it helps you out.
Sathish Pabbathi99 reputationPosted May 13, 2013, 10:39 PM EDT
Riddhi ValechaRank #794 · 2.9K reputationPosted May 14, 2013, 8:31 AM EDT
private void TextBox_KeyPress(object sender, KeyPressEventArgs e) { e.KeyChar = Char.ToUpper(e.KeyChar); } ----- Hope this helps...