Regular expression
-
Hi all... I have the expression in RegularExpressionValidator using the ValidationExpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*" checking the email. I have a java script which adds enter text... if the user has entered nothing in the text box. But when i submit the form the regular expression validator comes into action and tells the user that "enter text..." is invalid as given. Can anyone tell me a way to modify the above validation expression so as it will accept a valid email or the string "enter text...". Please Note this is a requirement and this requirement cannot be modified. Waiting in anticipation.
Bye
-
Hi all... I have the expression in RegularExpressionValidator using the ValidationExpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*" checking the email. I have a java script which adds enter text... if the user has entered nothing in the text box. But when i submit the form the regular expression validator comes into action and tells the user that "enter text..." is invalid as given. Can anyone tell me a way to modify the above validation expression so as it will accept a valid email or the string "enter text...". Please Note this is a requirement and this requirement cannot be modified. Waiting in anticipation.
Bye
U have to use javascript for both valid email or the string "enter text...". Check If Text is "enter text..." return true else validate email Best Regard Pathan
---------------------------------------------------