i have following control masked edit phone number. have tested regular expression , appears working correctly. however, when have attempted enter correct phone number, returns error message , not sure why.
<asp:textbox id="txtphone" width="10em" runat="server" maxlength="14" validationgroup="test"></asp:textbox> <asp:regularexpressionvalidator validationexpression="((\(\d{3}\) ?)| (\d{3}-))?\d{3}-\d{4}" controltovalidate="txtphone" id="regexpval_txtphone" runat="server" cssclass="field-validation-error" errormessage="invalid format (use: (xxx) xxx-xxxx)" display="dynamic" forecolor="red" validationgroup="test" /> <ajaxtoolkit:maskededitextender id="txtphone_maskededitextender" runat="server" mask="(999) 999-9999" targetcontrolid="txtphone" clearmaskonlostfocus="false" /> any ideas why this should not work?
Comments
Post a Comment