Link to home
Start Free TrialLog in
Avatar of Kaashayp N
Kaashayp N

asked on

Regular expression validation in MVC

Regular expression validation in mvc class with co.in or .com. I am having my expression as follows
[RegularExpression(@"^\w+([-+.']\w+)*@company-usa.com$", ErrorMessage = "Not a valid email")]

Open in new window

I would like to validate with
@company.in

Open in new window

too like user@company-usa.com or user@company.in
ASKER CERTIFIED SOLUTION
Avatar of David Johnson, CD
David Johnson, CD
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Kaashayp N
Kaashayp N

ASKER

Thanks