register Synfusion Licence Key Django Project

Hello sir

What the process to register Synfusion Licence Key in Django Projet in order to use it in HTML  or HTMX UI ? 

thanks for your answer


1 Reply

VM Vishwanathan Muruganantham Syncfusion Team September 23, 2024 12:51 PM UTC

Hi Pierre,

We understand that you have a query regarding Syncfusion licensing. To register a Syncfusion license key in a Django project, you can follow these steps to set the license key as an environment variable, avoiding hardcoding it in your application:

  1. Navigate to System Settings:
  • Go to Control Panel > All Control Panel Items > System and select Advanced system settings.
  1. Set Environment Variable:
  • Click on Environmental variables...
  • In the user variables section, click New and set the variable name as SyncfusionLicenseKey and the value as your license key.
  • Click OK to save the environment variable.
  1. Register the License Key in Your Django Project:
  • Ensure that you have the Syncfusion.Licensing.dll referenced in your project.
  • Use the following code to register the Syncfusion license key from the environment variable:


import os

from syncfusion.licensing import SyncfusionLicenseProvider

 

license_key = os.getenv('SyncfusionLicenseKey')

SyncfusionLicenseProvider.registerLicense(license_key)


Registering license: https://ej2.syncfusion.com/documentation/licensing/license-key-registration

For further references refer FAQ section: https://ej2.syncfusion.com/javascript/documentation/licensing/licensing-troubleshoot


Best regards,

Vishwanathan


Loader.
Up arrow icon