HI everyone,
I want regular expression for allow alphabetics and space only.
Regards,
Jeevan
Regular expression For Alphabetics and Space
2 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 attend4days leftRegister
Gomathi PalaniswamyRank #714 · 3.3K reputationPosted Sep 28, 2010, 4:03 AM EDT
try this expression
[a-zA-Z][a-zA-Z\s]+
jeevan mummadi140 reputationPosted Sep 30, 2010, 1:17 AM EDT
I am using below expression. But i am getting this error -->Unrecognized escape error at '\s'
Regex objAlphaPattern = new Regex("[a-zA-Z][a-zA-Z\s]+");
return (!objAlphaPattern.IsMatch(strVal));
Regards,
Jeevan.