Results 1 to 2 of 2

Thread: <asp:RegularExpressionValidator

  1. #1
    Join Date
    Dec 1969

    Default <asp:RegularExpressionValidator

    I&#039;m new to asp.net, I&#039;m trying to validate input on a textbox.<BR>I want the input format to have 4 characters followed by 3 numeric digits. I don&#039;t know how to format an expression for it. Thanks for your help in advance.

  2. #2
    Join Date
    Dec 1969

    Default RE: <asp:RegularExpressionValidator

    Not sure what you classify as a "character", i am going to assume you meant A-Z<BR><BR>[code language="VB.NET"]&#060;asp:textbox id="txtOne" runat="server" MaxLength="7"/&#062;<BR>&#060;asp:RegularExpressionValidator id="rgxOne" ControlToValidate="txtOne" ValidationExpression="^[A-Za-z]{4}d{3}$" runat="server"&#062;Error Message&#060;/asp:RegularExpressionValidator&#062;[/code]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts