Manages the global barcodes settings for the document.
function lt.Documents.DocumentBarcodes class lt.Documents.DocumentBarcodes() DocumentBarcodes manages the global barcodes settings of the document. It can be accessed through the Barcodes property of Document.
For more information, refer to Barcode processing with the Documents Library.
This example shows how to read the barcodes from a TIFF file.
Start with the example in Document and replace the example function call to the function below.
function barcodesExample() {// Load a new documentvar url = "https://demo.leadtools.com/images/tiff/barcode.tif";console.log("Loading document ...");var loadDocumentOptions = new lt.Documents.LoadDocumentOptions();lt.Documents.DocumentFactory.loadFromUri(url, loadDocumentOptions).done(function (doc) {console.log("Done. Reading barcodes ...");// Read all the barcodes in the first pagevar docPage = doc.pages.item(0);docPage.readBarcodes(lt.LeadRectD.empty, 0, null).done(function (barcodes) {console.log("Number of barcodes read " + barcodes.length);for (var i = 0; i < barcodes.length; i++) {var barcodeData = barcodes[i];console.log(" Symbology:" + barcodeData.symbology);console.log(" Bounds:" + barcodeData.bounds.x + "," + barcodeData.bounds.y + "," + barcodeData.bounds.width + "," + barcodeData.bounds.height);console.log(" Value:" + barcodeData.value);}}).fail(function (jqXHR, statusText, errorThrown) {showServiceError(jqXHR, statusText, errorThrown);});}).fail(function (jqXHR, statusText, errorThrown) {showServiceError(jqXHR, statusText, errorThrown);});}
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET
