Using Iron Barcode License Keys
If you decide to purchase a license for IronBarcode, you will instantly receive a license key as soon as your payment has cleared. This License will be displayed on the checkout screen and also be sent by email.
Set your IronBarcode license key using code
Add this code to the startup of your application, your before IronBarcode is used.
IronBarCode.License.LicenseKey = "IRONBARCODE-MYLICENSE-KEY-1EF01";
IronBarCode.License.LicenseKey = "IRONBARCODE-MYLICENSE-KEY-1EF01";
IronBarCode.License.LicenseKey = "IRONBARCODE-MYLICENSE-KEY-1EF01"
VB C#
Set your IronBarcode license key using Web.Config or App.Config
To apply a key globally to your application using Web.Config or App.Config, add the following key to your config file in appSettings.
<configuration>
....
<appSettings>
<add key="IronBarCode.LicenseKey" value="IRONBARCODE-MYLICENSE-KEY-1EF01"/>
</appSettings>
....
</configuration>
Set your IronBarCode license key using a .Net Core appsettings.json file
To apply a key globally to your application to a .Net Core:
- Add a JSON file to your project called appsettings.json in the root directory of your project
- Add a 'IronBarCode.LicenseKey' key to your JSON config file. The value should be your license key.
- Ensure that the file properties include Copy to Output Directory: Copy always
File: appsettings.json
{
"IronBarCode.LicenseKey":"IRONBARCODE-MYLICENSE-KEY-1EF01"
}
Test if your key has been installed correctly
bool result = IronBarCode.License.IsValidLicense("IRONBARCODE-MYLICENSE-KEY-1EF01");
bool result = IronBarCode.License.IsValidLicense("IRONBARCODE-MYLICENSE-KEY-1EF01");
Dim result As Boolean = IronBarCode.License.IsValidLicense("IRONBARCODE-MYLICENSE-KEY-1EF01")
VB C#