Resource Base
Table of contents

SDK Initialization

License

Get a trial key

  • A free public trial license is available for every new device for first use of Dynamsoft Document Viewer. The public trial license is the default key used in samples. You can also find the public trial license on the following parts of this page.
  • If your free key is expired, please visit Private Trial License Page to get a 30-day trial extension.

Get a full license

Initializiation

The following code snippets are using the public trial license to initialize the license. You can replace the public trial license with your own license key.

Dynamsoft.DDV.Core.license = "DLS2eyJvcmdhbml6YXRpb25JRCI6IjIwMDAwMSJ9"; // Public trial license which is valid for 24 hours
Dynamsoft.DDV.Core.engineResourcePath = "https://cdn.jsdelivr.net/npm/dynamsoft-document-viewer@latest/dist/engine";// Lead to a folder containing the distributed WASM files
await Dynamsoft.DDV.Core.loadWasm();
await Dynamsoft.DDV.Core.init(); 

deviceFriendlyName

A human-readable name for the device which corresponds to its UUID is able to set during initialization. This name will appear in the device details table when you check the statistics of the according license.

Dynamsoft.DDV.Core.license = "DLS2eyJvcmdhbml6YXRpb25JRCI6IjIwMDAwMSJ9";// Public trial license which is valid for 24 hours
Dynamsoft.DDV.Core.engineResourcePath = "https://cdn.jsdelivr.net/npm/dynamsoft-document-viewer@latest/dist/engine"; // Lead to a folder containing the distributed WASM files
Dynamsoft.DDV.Core.deviceFriendlyName = "Dynamsoft-iPhone"; // A string representing the device which is easier to recognize than its UUID
await Dynamsoft.DDV.Core.loadWasm();
await Dynamsoft.DDV.Core.init(); 

This page is compatible for:

Is this page helpful?

YesYes NoNo

In this article:

latest version

  • Latest version(2.0)
  • Version 1.x
    • Version 1.1
Change +