The barcode symbologies supported by LEADTOOLS
lt.Barcode.BarcodeSymbology = {
unknown: 0,
ean13: 1,
ean8: 2,
upca: 3,
upce: 4,
code3Of9: 5,
code128: 6,
codeInterleaved2Of5: 7,
codabar: 8,
uccean128: 9,
code93: 10,
eanext5: 11,
eanext2: 12,
msi: 13,
code11: 14,
codeStandard2Of5: 15,
gs1Databar: 16,
gs1DatabarLimited: 17,
gs1DatabarExpanded: 18,
patchCode: 19,
postNet: 20,
planet: 21,
australianPost4State: 22,
royalMail4State: 23,
usps4State: 24,
gs1DatabarStacked: 25,
gs1DatabarExpandedStacked: 26,
pdf417: 27,
microPDF417: 28,
datamatrix: 29,
qr: 30,
aztec: 31,
maxi: 32,
microQR: 33,
pharmaCode: 34
}
lt.Barcode.BarcodeSymbology = {
unknown: 0,
ean13: 1,
ean8: 2,
upca: 3,
upce: 4,
code3Of9: 5,
code128: 6,
codeInterleaved2Of5: 7,
codabar: 8,
uccean128: 9,
code93: 10,
eanext5: 11,
eanext2: 12,
msi: 13,
code11: 14,
codeStandard2Of5: 15,
gs1Databar: 16,
gs1DatabarLimited: 17,
gs1DatabarExpanded: 18,
patchCode: 19,
postNet: 20,
planet: 21,
australianPost4State: 22,
royalMail4State: 23,
usps4State: 24,
gs1DatabarStacked: 25,
gs1DatabarExpandedStacked: 26,
pdf417: 27,
microPDF417: 28,
datamatrix: 29,
qr: 30,
aztec: 31,
maxi: 32,
microQR: 33,
pharmaCode: 34
}
Value | Member | Description |
---|---|---|
0 | Unknown | Unknown symbology type. This has a special meaning in some of the methods that use BarcodeSymbology. For example, you can pass Unknown as the symbology parameter for the DocumentPage.ReadBarcodes method to indicate that the barcode type is unknown. It will also instruct the engine to read the first barcode found in the image using the other parameters. |
1 | EAN13 | (International Article Number with 13 digits) symbology. Used internationally with consumer products. |
2 | EAN8 | Derived from the longer European Article Number (EAN-13) code. It was introduced for use on small packages where an EAN-13 barcode would be too large. |
3 | UPCA | (Universal Product Code). Used with consumer products in the United States. |
4 | UPCE | The short version of UPC-A. |
5 | Code3Of9 | (Code 39) type. Used especially in non-retail environments. |
6 | Code128 | Code 128 type. Very dense code, used extensively worldwide. |
7 | CodeInterleaved2Of5 | Interleaved 2 of 5 type. Used in warehouse, industrial applications. |
8 | Codabar | (Ames Code/USD-4/NW-7/2 of 7 Code) type. Used in libraries and blood banks. |
9 | UCCEAN128 | UCCEAND 128 type |
10 | Code93 | Code 93 type. Compressed form of Code 39 |
11 | EANEXT5 | 5-digit supplemental type. May be used with UPCA, UPCE, EAN13 and EAN8 on books to indicate a suggested retail price. |
12 | EANEXT2 | 2-digit supplemental type. May be used with UPCA, UPCE, EAN13 and EAN8 to indicate magazines and newspaper issue numbers. |
13 | MSI | MSI (Modified Plessey) type. Used to mark retail shelves for inventory control. |
14 | Code11 | Code 11 (USD-8) type. Used in labeling telecommunications equipment. |
15 | CodeStandard2Of5 | Standard 2 of 5 (Industrial 2 of 5) type. Used in the photofinishing, warehouse sorting industries and sequentially numbering airline tickets. |
16 | GS1Databar | GS1 Databar (formerly RSS14) type. Used in grocery industry, healthcare, and where items are too small to allow for older barcode symbologies. |
17 | GS1DatabarLimited | GS1 Databar (formerly RSS14) Limited type. It is a short version of GS1 Databar (formerly RSS14). |
18 | GS1DatabarExpanded | GS1 Databar (formerly RSS14) Expanded type. It encodes item identification plus supplementary strings such as weight and date. Used in grocery industry and healthcare. |
19 | PatchCode | Patch Code type. Used only for batch separation and scanner control, primarily with Kodak scanners. |
20 | PostNet | (Postal Numeric Encoding Technique). Used by the United States Postal Service to assist in directing mail. |
21 | Planet | (Postal Alpha Numeric Encoding Technique). Used by the United States Postal Service to identify and track pieces of mail during delivery. |
22 | AustralianPost4State | Australian Post 4-State type. |
23 | RoyalMail4State | Royal Mail (RM4SCC) 4-State type. |
24 | USPS4State | USPS OneCode 4-State Barcode (4BC) type. |
25 | GS1DatabarStacked | GS1 Databar (formerly RSS14) Stacked / GS1 Databar Stacked Omni-Directional types. Used as GS1 Databar when the available space is too narrow for the standard GS1 Databar. |
26 | GS1DatabarExpandedStacked | GS1 Databar (formerly RSS14) Expanded Stacked barcode type. Used as GS1 Databar Expanded when the available space is too narrow to fit in one line. |
27 | PDF417 | (Portable Data File). 2D symbol used in a variety of applications, primarily transport, identification cards, and inventory management. Note, the PDF417 barcode symbology does not have any relation to Adobe PDF (Portable Document Format). |
28 | MicroPDF417 | (Portable Data File). Version of PDF417 that can hold up to 150 bytes of data. Note, the MicroPDF417 barcode symbology does not have any relation to Adobe PDF (Portable Document Format). |
29 | Datamatrix | Datamatrix. 2D symbol code used for marking small items. |
30 | QR | (short for Quick Response). 2D symbol used by dedicated QR barcode readers and camera phones. |
31 | Aztec | Aztec. 2D symbol used for train tickets, airline tickets and government documents. This barcode is able to reduce the required space over other matrix barcode as it does not require a surrounding quiet zone. |
32 | Maxi | MaxiCode. 2D symbol developed and used by the United Parcel Service to idand track pieces of mail during delivery. |
33 | MicroQR | Micro QR. 2D symbol used where symbol size is limited. There are four sizes; the largest is capable of encoding 35 characters. Some sizes support more than one error correction level. |
34 | PharmaCode | PharmaCode type. Used in the pharmaceutical industry as a packing control system. |
import { DocumentHelper } from "../../utilities/DocumentHelper";
export class LEADDocument_BarcodesExample {
public constructor() {
lt.RasterSupport.setLicenseUri("https://demo.leadtools.com/licenses/js/LEADTOOLSEVAL.txt", "EVAL", null);
DocumentHelper.initFactory();
}
public run = (buttonID: string) => {
const exampleButton = document.getElementById(buttonID);
exampleButton.onclick = this.readBarcodes;
}
readBarcodes = () => {
const url = "https://demo.leadtools.com/images/tiff/barcodes.tif";
const loadDocumentOptions = new lt.Document.LoadDocumentOptions();
DocumentHelper.log("Loading document...");
lt.Document.DocumentFactory.loadFromUri(url, loadDocumentOptions)
.done((document: lt.Document.LEADDocument) => {
DocumentHelper.log("Done. Reading barcodes...");
// Read all the barcodes in the first page
const docPage = document.pages.item(0);
docPage.readBarcodes(lt.LeadRectD.empty, 0, null)
.done((barcodes) => {
DocumentHelper.log("Number of barcodes read: " + barcodes.length + " (data in console)", barcodes);
})
.fail(DocumentHelper.showServiceError);
})
.fail(DocumentHelper.showServiceError);
}
}
export class DocumentHelper {
static showServiceError = (jqXHR, statusText, errorThrown) => {
alert("Error returned from service. See the console for details.");
const serviceError = lt.Document.ServiceError.parseError(jqXHR, statusText, errorThrown);
console.error(serviceError);
}
static log = (message: string, data?: any) => {
const outputElement = document.getElementById("output");
if (outputElement) {
const time = (new Date()).toLocaleTimeString();
const textElement = document.createElement("p");
textElement.innerHTML = (outputElement.childElementCount + 1) + " [" + time + "]: " + message;
outputElement.insertBefore(textElement, outputElement.firstChild);
}
if (!data)
console.log(message);
else
console.log(message, data);
}
static initFactory = () => {
// To communicate with the DocumentsService, it must be running!
// Change these parameters to match the path to the service.
lt.Document.DocumentFactory.serviceHost = "http://localhost:40000";
lt.Document.DocumentFactory.servicePath = "";
lt.Document.DocumentFactory.serviceApiPath = "api";
}
}
import { DocumentHelper } from "../../utilities/DocumentHelper";
export class LEADDocument_BarcodesExample {
constructor() {
lt.RasterSupport.setLicenseUri("https://demo.leadtools.com/licenses/js/LEADTOOLSEVAL.txt", "EVAL", null);
DocumentHelper.initFactory();
}
run = (buttonID) => {
const exampleButton = document.getElementById(buttonID);
exampleButton.onclick = this.readBarcodes;
}
readBarcodes = () => {
const url = "https://demo.leadtools.com/images/tiff/barcodes.tif";
const loadDocumentOptions = new lt.Document.LoadDocumentOptions();
DocumentHelper.log("Loading document...");
lt.Document.DocumentFactory.loadFromUri(url, loadDocumentOptions)
.done((document) => {
DocumentHelper.log("Done. Reading barcodes...");
// Read all the barcodes in the first page
const docPage = document.pages.item(0);
docPage.readBarcodes(lt.LeadRectD.empty, 0, null)
.done((barcodes) => {
DocumentHelper.log("Number of barcodes read: " + barcodes.length + " (data in console)", barcodes);
})
.fail(DocumentHelper.showServiceError);
})
.fail(DocumentHelper.showServiceError);
}
}
export class DocumentHelper {
static showServiceError = (jqXHR, statusText, errorThrown) => {
alert("Error returned from service. See the console for details.");
const serviceError = lt.Document.ServiceError.parseError(jqXHR, statusText, errorThrown);
console.error(serviceError);
}
static log = (message, data) => {
const outputElement = document.getElementById("output");
if (outputElement) {
const time = (new Date()).toLocaleTimeString();
const textElement = document.createElement("p");
textElement.innerHTML = (outputElement.childElementCount + 1) + " [" + time + "]: " + message;
outputElement.insertBefore(textElement, outputElement.firstChild);
}
if (!data)
console.log(message);
else
console.log(message, data);
}
static initFactory = () => {
// To communicate with the DocumentsService, it must be running!
// Change these parameters to match the path to the service.
lt.Document.DocumentFactory.serviceHost = "http://localhost:40000";
lt.Document.DocumentFactory.servicePath = "";
lt.Document.DocumentFactory.serviceApiPath = "api";
}
}
<!doctype html>
<html lang="en">
<title>Document Example | Barcodes</title>
<head>
<script src="https://code.jquery.com/jquery-2.2.4.min.js"
integrity="sha256-BbhdlvQf/xTY9gja0Dq3HiwQF8LaCRTXxZKRutelT44=" crossorigin="anonymous"></script>
<script src="../../LT/Leadtools.js"></script>
<script src="../../LT/Leadtools.Controls.js"></script>
<script src="../../LT/Leadtools.Annotations.Engine.js"></script>
<script src="../../LT/Leadtools.Annotations.Designers.js"></script>
<script src="../../LT/Leadtools.Annotations.Rendering.Javascript.js"></script>
<script src="../../LT/Leadtools.Annotations.Automation.js"></script>
<script src="../../LT/Leadtools.ImageProcessing.Main.js"></script>
<script src="../../LT/Leadtools.ImageProcessing.Color.js"></script>
<script src="../../LT/Leadtools.ImageProcessing.Core.js"></script>
<script src="../../LT/Leadtools.ImageProcessing.Effects.js"></script>
<script src="../../LT/Leadtools.Document.js"></script>
<script src="../../LT/Leadtools.Document.Viewer.js"></script>
<link rel="stylesheet" type="text/css" href="../../css/examples.css">
<!-- All demo files are bundled and appended to the window -->
<script src="../../bundle.js" type="text/javascript"></script>
</head>
<body>
<div>
<button type="button" id="exampleButton">Run Example</button>
</div>
<div id="output"></div>
<div>
<img id="img" />
</div>
</body>
<script>
window.onload = () => {
const example = new window.examples.LEADDocument.Barcodes();
example.run("exampleButton");
};
</script>
</html>
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document