DL/ID Parsing Library
DL/ID cards are widely used for storing personal information such as first name, last name, birth date, address, etc. They also contain special information related to driving activity including DL number, class and restrictions. Because of the utility of this data, there is a high demand for mobile applications that can scan and process DL/ID information.
Magnetic Stripe and 2D formats greatly vary from one state to another, causing numerous difficulties when attempting to parse information encoded in each DL. For instance, some cards may contain tracks in the inverted order, while others may use slightly shifted track positions for storing fields.
As a solution, IDScan.net developed a DL/ID Parsing library for multiple development environments. The whole list can be found on our download page. We collected 10+ years of ID formats from the US, Canada, and many other countries and tested each one to ensure every DL/ID card is parsed with precision.
Implementation Instructions Using Microsoft Visual Studio
for .NET languages
- Download dlplib from the link below and extract files.
- With your project open, go to Project -> Add Reference and browse path to dlplib.dll.
Example projects can found below or on our SDK downloads here.
.NET Library Properties, Methods, Events
Object that enables access to parsed information from an ID.
|DriverLicense()||Initializes an instance of the DriverLicense class|
|FullName||Full name of cardholder|
|Address1||First line of address of cardholder|
|Address2||Second line of address of cardholder|
|City||City of cardholder address|
|JurisdictionCode||State of cardholder address|
|Country||Country of cardholder|
|PostalCode||Postal code of cardholder address, if unknown, zeroes will be used|
|BirthDate||Birth date of cardholder|
|Gender||Gender of cardholder|
|Height||Height of cardholder, followed by “in” or “cm”|
|ExpirationDate||Date on which the driving and identification privileges granted by the document are no longer valid (MMDDCCYY for U.S.)|
|EyeColor||Color of cardholder’s eyes, as defined in ANSI D-20 codes|
|LicenseNumber||License number of cardholder|
|DocumentType||Can be a driver’s license or ID|
ID – Identity Card
DL – Driver License
CC – Bank Card
HC – Health Card
TD – Machine Readable Travel Document
CAC – Department of Defense and Common Access Card
|HairColor||Hair color of cardholder. Brown, black, blonde, gray, red/auburn, sandy, white|
|IIN||Issuer Identification Number – the full 6-digit IIN should be encoded|
|IssueDate||Issue date of DL/ID|
|NamePrefix||NamePrefix of cardholder|
|NameSuffix||NameSuffix of cardholder|
|Race||Race or ethnicity of cardholder as defined in ANSI D20|
|Specification||Standard of scanned document|
|WeightKG||Physical weight or weight range in KG.|
up to 31
32 – 45
46 – 59
|WeightLBS||Physical weight or weight range in pounds.|
up to 70
71 – 100
101 – 130
|ClassificationCode||Driver License classification code as defined by Federal Highway regulations and by AAMVA; others are defined by DL Classification Code Standards|
|RestrictionCode||Driver License restriction code that curtail driving privileges|
|VehicleClassCode||Jurisdiction-specific vehicle class / group code, designating the type of vehicle the cardholder has privilege to drive|
|EndorsementsCode||Any endorsements on a driver license which authorize the operation of specified types of vehicles or the operation of vehicles carrying specified loads. Endorsements shall be specific to classification of a driver license|
|Method Name||Description||Return Value|
|ParseText(System.String)||Parses scanned text of ID||Returns a DriverLicense object on success and null on error|
|ExtractInfo(System.String)||Extracts information from scanned driver’s license or ID. This is a deprecated method, should be utilized only in such cases when a static call cannot be used||Returns true on success and false on error|
This class is similar to DriverLicense but also provides support for data types such as date, boolean, string, etc and does not contain an ExtractInfo() method.
|DriverLicenseEx()||Initializes an instance of the DriverLicenseEx class|
Fields are the same as DriverLicense.
|Method Name||Description||Return Value|
|ParseText(System.String)||Parses scanned text of ID.||Returns a DriverLicense object on success and null on error|