Apply the License Key
If you haven't get a license key, please check out how to obtain a license key.
PDF Generation SDK currently supports two authentication methods to verify license keys: online authentication and offline authentication.
Learn about:What is the authentication mechanism of ComPDFKit's license?What are the differences between Online Authentication and Offline Authentication?
Copying the License Key
Accurately obtaining the license key is crucial for the application of the license.
In the email you received, locate the
XMLfile containing the license key.Open the
XMLfile.
Offline License:
xml
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<license version="1">
<platform>linux</platform>
<starttime>xxxxxxxx</starttime>
<endtime>xxxxxxxx</endtime>
<key>LICENSE_KEY</key>
</license>- Copy the LICENSE_KEY from the
<key>LICENSE_KEY</key>field.
Apply the License Key
You can authenticate in the following ways:
java
NativeComPDF.initialize("LICENSE_KEY", "your deviceId", "", Constants.LIB_DIR_NAME);