Resource Base
Table of contents

Thanks for downloading Dynamsoft Barcode Reader Package!

Your download will start shortly. If your download does not begin, click here to retry.

JavaScript API Reference - BarcodeReader Properties

Property Description
_bUseFullFeature If set to true, use the full-featured WASM module.
engineResourcePath Gets or sets the engine (WASM) location.
productKeys Gets or sets the Dynamsoft Barcode Reader SDK product keys.
version Gets current version.
licenseServer Gets or sets the URL of the license server(s) used for authentication and tracking.
organizationID Specify the Organization ID which determines which licenses are available.
handshakeCode Gets or sets the handshake code to interact with the license server(s).
sessionPassword Gets or sets the session password of the handshake code set in license tracking server.

_bUseFullFeature

Set usage of compact or full featured SDK. If set to true, use the fully-featured WASM module.

Note: this API may change in the future.

Dynamsoft.DBR.BarcodeReader._bUseFullFeature = Boolean

Default Value

false for web

Sample

Dynamsoft.DBR.BarcodeReader._bUseFullFeature = true;
await Dynamsoft.DBR.BarcodeReader.loadWasm();

:+1: Tips and Tricks

  • Check out what features are included in compact and full version.
  • This property must be set before loadWasm.
  • We recommend using the compact version in video decoding for its small size and quick initialization.
  • This property cannot be set in NodeJS and will always use the fully featured version.

engineResourcePath

Get or set the Barcode Reader SDK engine path. The path should lead to a folder containing the JS and WASM files for distribution.

engineResourcePath = value

Property Value

value string

Sample

Dynamsoft.DBR.BarcodeReader.engineResourcePath = "https://cdn.jsdelivr.net/npm/dynamsoft-javascript-barcode@8.0.0/dist/";

await Dynamsoft.DBR.BarcodeReader.loadWasm();

productKeys

Get or set the Barcode Reader SDK product key. From version 8.0, the product key can also be a handshakeCode. Please visit our user portal to obtain a trial license.

get

productKeys() returns string

Return Value

string

set

productKeys(value) returns void

Parameters

value string

Return Value

void

Sample

In the

<script src="https://cdn.jsdelivr.net/npm/dynamsoft-javascript-barcode@@8.0.0/dist/dbr.js" data-productKeys="PRODUCT-KEYS"></script>

In JavaScript

Dynamsoft.DBR.BarcodeReader.productKeys = "1000**601-1000***44"; // Set the handshakeCode

version

Get the currently used version of Barcode Reader SDK.

version returns string

Return Value

string

licenseServer

Gets or sets the URL of the license tracking server used to authenticate the license (handshakeCode) and track barcode reading usage. When set to null (default value), it will connect to Dynamsoft’s license tracking servers for online verification. A self hosting option is available. Learn more about License Tracking Server 2.0. Set this API before calling createInstance.

get

licenseServer() returns string

Return Value

string

set

licenseServer(value) returns void

Parameters

value string

Return Value

void

Sample

Dynamsoft.DBR.BarcodeReader.licenseServer = ["https://your.mainServer.com", "https://your.backupServer.com"];

await Dynamsoft.DBR.BarcodeReader.loadWasm();

organizationID

Get or set the organization ID. Check out more on how to specify the Organization ID.

Sample

Dynamsoft.DBR.BarcodeReader.organizationID = "123456"; // replace the number 123456 with YOUR-ORGANIZATION-ID

handshakeCode

Get or set the handshakeCode. Learn more about What is handshakeCode. Set this API before calling createInstance.

The API productKeys can be used to set the handshakeCode as well but we recommend using this new API instead.

get

handshakeCode() returns string

Return Value

string

set

handshakeCode(value) returns void

Parameters

value string

Return Value

void

Sample

Dynamsoft.DBR.BarcodeReader.handshakeCode = "1000**601-1000***44";

sessionPassword

Get or set the session password used for authentication of the license (handshake code) associated with the application. Learn more about session password in License Tracking Server 2.0. Set this API before calling createInstance.

get

sessionPassword() returns string

Return Value

string

set

sessionPassword(value) returns void

Parameters

value string

Return Value

void

Sample

Dynamsoft.DBR.BarcodeReader.sessionPassword = "MyPassw0rd";
await Dynamsoft.DBR.BarcodeReader.loadWasm();

This page is compatible for:

Version 7.5

Is this page helpful?

YesYes NoNo

In this article:

latest version

  • Latest Version
  • version 8.1.2
  • version 8.0
  • version 7.6
  • version 7.5
Change +
© 2003–2021 Dynamsoft. All rights reserved.
Privacy Statement / Site Map / Home / Purchase / Support