I am using the RegularExpressionValidator control and I have a form element that I want to allow numbers or a period is all. I believe I have the syntex right with
VB Code:
<asp:RegularExpressionValidator ControlToValidate="txtRetail" ErrorMessage="Retail" Text="Example:....." runat="server" ValidationExpression="^[0-9]{1,6}\.{0,}[0-9]{0,2}$" />
Works except if I put no value it gets by. I tried ^\S|.... but that didn't work.
Any ideas?
Thanks in advance.




Reply With Quote