Director
22 Points
Joined June 2011
I have also worked out formula if useful to any one
=IF(LEN(Tbl_26Q[[#This Row],[Pan]])=10,
IF(ISNUMBER(VALUE(MID(Tbl_26Q[[#This Row],[Pan]],6,4)))=TRUE,
IF(ISERROR(INDIRECT(MID(Tbl_26Q[[#This Row],[Pan]],1,1) & "1"))=FALSE,
IF(ISERROR(INDIRECT(MID(Tbl_26Q[[#This Row],[Pan]],2,1) & "1"))=FALSE,
IF(ISERROR(INDIRECT(MID(Tbl_26Q[[#This Row],[Pan]],3,1) & "1"))=FALSE,
IF(ISERROR(INDIRECT(MID(Tbl_26Q[[#This Row],[Pan]],5,1) & "1"))=FALSE,
IF(ISERROR(INDIRECT(MID(Tbl_26Q[[#This Row],[Pan]],10,1) & "1"))=FALSE,
IF(MID(Tbl_26Q[[#This Row],[Pan]],4,1)="P","OK",
IF(MID(Tbl_26Q[[#This Row],[Pan]],4,1)="H","OK",
IF(MID(Tbl_26Q[[#This Row],[Pan]],4,1)="C","OK",
IF(MID(Tbl_26Q[[#This Row],[Pan]],4,1)="F","OK",
"Error-4char is Not P/H/C/F")))),"Error-10 Char not Alpha"),"Error-5 Char not Alpha"),"Error-3 Char not Alpha"),"Error-2 Char not Alpha"),"Error-1 Char not Alpha"),"Error-6to9 Char not Number"), "Error-Lenght Is not 10")
i have created Table Tbl_26Q and Row name Pan u can do modication as per you need
i have added only 4 validation for 4th aphabate u can and more also
C — Company
F — Firm
H — HUF(Hindu Undivided Family)
P — Person
A — Association of Persons (AOP)
B — Body of Individuals (BOI)
G — Government
J — Artificial Juridical Person
L — Local Authority
T — AOP (Trust)
Regrds
Hemant