1. #1
    Sencha User
    Join Date
    May 2013
    Posts
    33
    Vote Rating
    0
    r6174 is on a distinguished road

      0  

    Default PAN Card (Indian) validator

    PAN Card (Indian) validator


    Hi, if any one (in India) wants validator for PAN Card Validation they can use the following code and define vtype as 'PANFormat' or you can use maskre:/^[a-zA-Z][a-zA-Z][a-zA-Z][ABCFGHJLPTabcfghjlpt][a-zA-Z][0-9][0-9][0-9][0-9][a-zA-Z]+$/, for the textfield

    Ext.apply(Ext.form.VTypes,{
    alphaNumericRe :/^[a-zA-Z][a-zA-Z][a-zA-Z][ABCFGHJLPTabcfghjlpt][a-zA-Z][0-9][0-9][0-9][0-9][a-zA-Z]+$/,
    PANFormat: function(v) {
    return this.alphaNumericRe.test(v);
    },
    PANFormatText: "Invalid PAN No. format.It must be in 'ABCDE1234F' format"
    });

    Thanks,

  2. #2
    Sencha - Support Team
    Join Date
    Feb 2013
    Location
    California
    Posts
    3,402
    Vote Rating
    62
    Gary Schlosberg is a jewel in the rough Gary Schlosberg is a jewel in the rough Gary Schlosberg is a jewel in the rough

      1  

    Default


    Thanks for sharing your work with the community!
    Get on the Fast Track with Sencha Training http://sencha.com/training

    Are you a Sencha products veteran who has wondered what it might be like to work at Sencha? If so, please reach out to our recruiting manager: sheryl@sencha.com

Thread Participants: 1

Tags for this Thread