ByteScout Barcode Suite - VBScript - Batch read barcodes from files with barcode reader sdk - ByteScout

ByteScout Barcode Suite – VBScript – Batch read barcodes from files with barcode reader sdk

  • Home
  • /
  • Articles
  • /
  • ByteScout Barcode Suite – VBScript – Batch read barcodes from files with barcode reader sdk

How to batch read barcodes from files with barcode reader sdk in VBScript and ByteScout Barcode Suite

Learn to code in VBScript to batch read barcodes from files with barcode reader sdk with this step-by-step tutorial

Source code documentation samples give simple and easy method to install a needed feature into your application. ByteScout Barcode Suite: the bundle that privides 3 SDK products to generate barcodes (Barcode SDK), read barcodes (Barcode Reaer SDK) and read and write spreadsheets (Spreadsheet SDK). It can batch read barcodes from files with barcode reader sdk in VBScript.

These VBScript code samples for VBScript guide developers to speed up coding of the application when using ByteScout Barcode Suite. This VBScript sample code is all you need for your app. Just copy and paste the code, add references (if needs to) and you are all set! Use of ByteScout Barcode Suite in VBScript is also described in the documentation included along with the product.

Our website gives trial version of ByteScout Barcode Suite for free. It also includes documentation and source code samples.

On-demand (REST Web API) version:
 Web API (on-demand version)

On-premise offline SDK for Windows:
 60 Day Free Trial (on-premise)

BatchReadFromFiles.vbs
      
if WScript.Arguments.Count < 2 Then MsgBox "Run with the folder path as the argument" & vbCRLF & vbCRLF & "BatchReadFromFiles.vbs <InputFolder> <OutputFolder>" WScript.Quit 0 End If Set objFSO = CreateObject("Scripting.FileSystemObject") ' define allowed input images extensions inputImagesExtensions = "JPG,JPEG,PNG,BMP,PDF,TIF" Set reader = CreateObject("Bytescout.BarCodeReader.Reader") ' Set barcode types for searching reader.BarcodeTypesToFind.Code39 = True reader.BarcodeTypesToFind.QRCode = True reader.BarcodeTypesToFind.PDF417 = True reader.BarcodeTypesToFind.EAN13 = True Set objInputFolder = objFSO.GetFolder(WScript.Arguments(0)) Set objResultsFile = objFSO.CreateTextFile(WScript.Arguments(1), True) Call ProcessFolder(objInputFolder) WScript.Quit 0 Sub ProcessFolder(folder) Set objFolder = objFSO.GetFolder(folder.Path) Set colFiles = objFolder.Files For Each objFile in colFiles ' Check the file type If inStr(inputImagesExtensions, UCase(objFSO.GetExtensionName(objFile.Name))) > 0 Then ' Read barcode from file WScript.Echo "Reading from: " & objFile.Path reader.ReadFromFile objFile.Path Dim csv csv = reader.ExportFoundBarcodesToCSV_4 objResultsFile.Write csv End If Next For Each subFolder in folder.SubFolders ProcessFolder subFolder Next End Sub

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout Barcode Suite Home Page

Explore ByteScout Barcode Suite Documentation

Explore Samples

Sign Up for ByteScout Barcode Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

run.bat
      
REM running from the command line cscript.exe BatchReadFromFiles.vbs "input" "results.csv" pause

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout Barcode Suite Home Page

Explore ByteScout Barcode Suite Documentation

Explore Samples

Sign Up for ByteScout Barcode Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

VIDEO

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout Barcode Suite Home Page

Explore ByteScout Barcode Suite Documentation

Explore Samples

Sign Up for ByteScout Barcode Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

Tutorials:

prev
next