ByteScout Barcode Reader SDK - VB.NET - Batch Read From Files - ByteScout

ByteScout Barcode Reader SDK – VB.NET – Batch Read From Files

  • Home
  • /
  • Articles
  • /
  • ByteScout Barcode Reader SDK – VB.NET – Batch Read From Files

How to batch read from files in VB.NET using ByteScout BarCode Reader SDK

This tutorial will show how to batch read from files in VB.NET

Learn how to batch read from files in VB.NET with this source code sample. What is ByteScout BarCode Reader SDK? It is the SDK for reading of barcodes from PDF, images and live camera or video. Almost every common type like Code 39, Code 128, GS1, UPC, QR Code, Datamatrix, PDF417 and many others are supported. Supports noisy and defective images and docs. Includes optional documents splitter and merger for pdf and tiff based on found barcodess. Batch mode is supported for superior performance using multiple threads. Decoded values are easily exported to JSON, CSV, XML and to custom format. It can help you to batch read from files in your VB.NET application.

VB.NET code samples for VB.NET developers help to speed up coding of your application when using ByteScout BarCode Reader SDK. In your VB.NET project or application you may simply copy & paste the code and then run your app! Use of ByteScout BarCode Reader SDK in VB.NET is also explained in the documentation included along with the product.

Trial version of ByteScout BarCode Reader SDK is available for free. Source code samples are included to help you with your VB.NET app.

Try ByteScout BarCode Reader SDK today:  60 Day Free Trial (on-premise) or  Web API (on-demand version)

Module1.vb
      
Imports System.IO Imports Bytescout.BarCodeReader Module Module1 Sub Main() ' Get all JPG files from the current folder Dim filesToScan As String() = Directory.GetFiles(Directory.GetCurrentDirectory(), "*.jpg") ' Open file to export results Dim resultsCsvFile As StreamWriter = File.CreateText("results.csv") ' Create barcode reader instance Dim reader As New Reader() reader.RegistrationName = "demo" reader.RegistrationKey = "demo" ' Set barcode types for searching reader.BarcodeTypesToFind.EAN13 = True ' Iterate over images and read barcodes For Each file As String In filesToScan Console.WriteLine() Console.WriteLine("Reading barcode(s) from image {0}", file) ' ----------------------------------------------------------------------- ' NOTE: We can read barcodes from specific page to increase performance . ' For sample please refer to "Decoding barcodes from PDF by pages" program. ' ----------------------------------------------------------------------- ' Read barcodes from image Dim barcodes As FoundBarcode() = reader.ReadFrom(file) ' Display results in console For Each barcode As FoundBarcode In barcodes Console.WriteLine("Found barcode with type '{0}' and value '{1}'", barcode.Type, barcode.Value) Next ' Write results to file in CSV format. Note, you can also export to TXT and XML. Dim csv = reader.ExportFoundBarcodesToCSV() resultsCsvFile.Write(csv) Next reader.Dispose() resultsCsvFile.Dispose() Console.WriteLine("Press any key to exit..") Console.ReadKey() End Sub End Module

Try ByteScout BarCode Reader SDK today:  60 Day Free Trial (on-premise) or  Web API (on-demand version)

VIDEO

ON-PREMISE VERSION INFORMATION

Get 60 Day Free Trial or Visit ByteScout BarCode Reader SDK Home Page

Explore ByteScout BarCode Reader SDK Documentation

Get ByteScout BarCode Reader SDK Free Training

WEB API

Get Your Free API Key

Explore Web API Documentation

Tutorials:

prev
next