setLicenseBuffer Method

Summary

Sets the runtime license for LEADTOOLS from a memory buffer and unlocks support for optional features such as LEADTOOLS Imaging Pro, Document, and Medical capabilities.

Syntax
TypeScript
JavaScript
setLicenseBuffer = function( 
   licenseBuffer, 
   developerKey 
) 
static setLicenseBuffer( 
   licenseBuffer: number[], 
   developerKey: string 
): void; 

Parameters

licenseBuffer

Byte array containing the LEADTOOLS runtime license to set.

developerKey

String containing the developer key.

Remarks

After you have obtained a runtime license and a developer key, call RasterSupport.setLicenseUri, RasterSupport.setLicenseBuffer or RasterSupport.setLicenseText at the start of your application to set the license, enable LEADTOOLS and disable the nag message.

You must use this method to set the runtime license for LEADTOOLS and to unlock support for any optional features that you have licensed. If you do not set a RELEASE runtime license, your application will display a nag message dialog at runtime, indicating that you have developed the application without a valid runtime license.

The LEADTOOLS JavaScript license is typically provided in a LEADTOOLS.lic.txt file and the developer key is typically provided in a LEADTOOLS.lic.key.txt file.

To set a license successfully, call this method with the following parameters:

Parameter Value
licenseBuffer The content of the LEADTOOLS.lic.txt file as a byte array.
developerKey The content of the LEADTOOLS.lic.key.txt file.

This method tries to set the license while blocking the application until completion. On errors, exceptions will be thrown with the error information.

In order to obtain a runtime license and a developer key, you must contact LEAD. For more information, refer to About LEADTOOLS Runtime Licenses.

For information about LEADTOOLS Document/Medical capabilities, contact LEAD.

To determine if support for optional features has been unlocked, use rasterSupport.isLocked.

To set the runtime license from a URI, use RasterSupport.setLicenseUri and to set the license from a text string, use RasterSupport.setLicenseText.

NOTE: As an alternative to calling setLicense, you can specify your runtime license in a folder on the server holding the application. Refer to RasterSupport.licenseDirectory for more information.

Help Version 21.0.2021.6.30
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

Leadtools Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.