Link Search Menu Expand Document

Decode Deutsche Post Identcode - VBScript

BarCode Reader SDK sample in VBScript demonstrating ‘Decode Deutsche Post Identcode’

ReadDeutschePostIdentcode.vbs
'*******************************************************************************************'
'                                                                                           '
' Download Free Evaluation Version From:     https://bytescout.com/download/web-installer   '
'                                                                                           '
' Also available as Web API! Get free API Key https://app.pdf.co/signup                     '
'                                                                                           '
' Copyright � 2017-2020 ByteScout, Inc. All rights reserved.                                '
' https://www.bytescout.com                                                                 '
' https://www.pdf.co                                                                        '
'*******************************************************************************************'

if (WScript.Arguments.Count < 1) Then

	MsgBox "Run with the file name as the argument" & vbCRLF & vbCRLF & "ReadDeutschePostIdentcode.vbs <InputFileName>"
 	WScript.Quit 0
End If

WScript.Echo "Reading barcode(s) from image " & WScript.Arguments(0)

Set reader = CreateObject("Bytescout.BarCodeReader.Reader")

reader.RegistrationName = "demo"
reader.RegistrationKey = "demo"

' Set barcode type to find
' "Deutsche Post Identcode" is subset of "Interleaved 2 of 5" barcode
reader.BarcodeTypesToFind.Interleaved2of5 = True

reader.ReadFromFile WScript.Arguments(0)

For i = 0 To reader.FoundCount - 1 

	' Write to console
	WScript.Echo "Found barcode with type '" & reader.GetFoundBarcodeType(i) & "' and value '" & reader.GetFoundBarcodeValue(i) & "'"
Next

' Cleanup
Set reader = Nothing
run.bat
REM running from the command line
cscript.exe ReadDeutschePostIdentcode.vbs DeutschePostIdentcode.png
pause

Download Source Code (.zip)

Return to the previous page Explore BarCode Reader SDK


Copyright © 2016 - 2021 ByteScout