LEADTOOLS Config License

In order to set a LEADTOOLS Runtime License, you must call RasterSupport.SetLicense during your application's startup code (preferably, before creating any LEADTOOLS classes or calling any other LEADTOOLS method). As an alternative to calling RasterSupport.SetLicense, you can place your license information in the Leadtools.dll.config file. Leadtools.dll will search for this file before any code that requires a license is invoked. If the license file is available, Leadtools.dll will apply the license(s) found in the file by reading the filename and developer key found and calling RasterSupport.SetLicense.

LEADTOOLS will search for the configuration in the same directory as the Leadtools.dll assembly. If you are consuming the DLL in a Web service or Web application, you can also add the configuration file to your App_Data or App_Code folders. The Leadtools.dll will determine whether these folders exist and contain a valid license file.

For more information, refer to ASP.NET Web Project Folder Structure.

The following is an example Leadtools.dll.config:

<?xml version="1.0" encoding="utf-8" ?> 
<configuration> 
  <configSections> 
     <section name="LeadtoolsLicenses" type="System.Configuration.NameValueFileSectionHandler" /> 
  </configSections> 
  <LeadtoolsLicenses> 
     <add key="D:\MyLicense.lic" value="MyDeveloperKeyGoesHere"/> 
  </LeadtoolsLicenses> 
</configuration> 

To determine the status of the license(s) specified in the Leadtools.dll.config file, check the value of the RasterSupport.ConfigLicenseStatus property.

Help Version 19.0.2017.10.27
Products | Support | Contact Us | Copyright Notices
© 1991-2017 LEAD Technologies, Inc. All Rights Reserved.
LEADTOOLS Imaging, Medical, and Document