Link to home
Start Free TrialLog in
Avatar of ITsolutionWizard
ITsolutionWizardFlag for United States of America

asked on control validation email

I use the following asp net email validator and it works fine until today I get an email (
And I want to ensure to accept this string '--'.

how can I do that with my current email validator?

<asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server"
            ControlToValidate="NewEmailAddressTextBox" CssClass="red bold"
            Display="Dynamic" ErrorMessage="*"
Avatar of David Favor
David Favor
Flag of United States of America image

Better to do this...

1) Split out user + host parts.

2) Run many regexp patterns against each separately.

Tip: Trying to create a validator with a single regular expression is near impossible to debug or extend.
Avatar of ITsolutionWizard


I guess how to create ValidationExpression to accept -- and @ will be helpful.
Avatar of ITsolutionWizard
Flag of United States of America image

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