Click here to Skip to main content
15,896,557 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
See more:
Hi,

I'm checking the email ID using this code.

string patternStrict = @"^[\w]+[\d._-]*[\w]*[@]{1}[\w]+[.]{1}[\w]+[,]?([\w]+[\d._-]*[\w]*[@]{1}[\w]+[.]{1}[\w]+[,]?)*$";


But if the email Id ends like ".net" , ".org" , ".biz" , ".de"
are not accepted as valid mail ID.

Please help me to solve this.
Thanks in Advance
Saranya1388
Posted
Updated 14-Nov-10 18:43pm
v2

you can use given code to validate your email ID
string patternStrict =@"^([\w-]+\.)*?[\w-]+@[\w-]+\.([\w-]+\.)*?[\w]+$"


:)
 
Share this answer
 
VB
hi, please see below code will work properly.
\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*
Cheers,
Jitendra Kumar
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900