RegularExpression PAN Validation

Ranjeet_8
Posted by Ranjeet_8 under Regular Expressions category on | Points: 40 | Views : 1989
<asp:TextBox ID="txt_PanNo" runat="server" MaxLength="10"></asp:TextBox>

<asp:RegularExpressionValidator ID="REV_txt_PanNo" runat="server"
ErrorMessage="Enter valid pan number! " ControlToValidate="txt_PanNo"
SetFocusOnError="true" ValidationExpression="[A-Z]{5}\d{4}[A-Z]{1}">
</asp:RegularExpressionValidator>
<br/>(case sensitive) eg:- ASDFG1234C

Comments or Responses

Login to post response