MENU
Table of contents

Thanks for downloading Dynamsoft Barcode Reader Package!

Your download will start shortly. If your download does not begin, click here to retry.

How to set full license in version 8.0

Different methods are used for setting trial and full license keys. In our demo or sample applications, we use .InitLicense() or .ProductKeys to set trial license keys.

For the purchased version, you need to use initLicenseFromLTS() to the set the Handshake Codes for your licenses.

You can set the license by following the steps below:

  1. Activate the license
  2. Configure the license (optional)
  3. Set the license in the code

Activate the license

Once you purchase a full license from our online store, you can find your license information at Customer Portal.

To activate the license, click “Please first activate the license” or the “Activate” button.

FullLicenseList

On the next page, set an Alias for your license or leave the default Alias and click the “Activate” button.

Read more on What is an Alias

SetAlias

On the following popup window, click the “OK” button.

ActivationContinue

Then you can see the message “Activate Success! You can start configuring your license now”. Click “start configuring your license” to continue.

ConfigLicense

You can repeat the above steps to activate other license keys.

Configure the license (optional)

After the license is activated, the Handshake Code will be generated automatically. Read more on What is a Handshake Code.

Basically, you can skip the step. But if you would like to edit the Handshake Codes for the license or view the statistics of a handshake code, please refer to how to manage the handshake code.

Set the license in the code

Code snippet in JavaScript:

    Dynamsoft.DBR.BarcodeReader.handshakeCode = "DynamsoftID-CustomCode";// Please replace the handshakeCode with your own
    Dynamsoft.DBR.BarcodeReader.sessionPassword = "The-Password-You-Set";
    let reader = await Dynamsoft.DBR.BarcodeReader.createInstance();

Code snippet in C:

   char errorBuf[512];
   DMLTSConnectionParameters paramters;
   DBR_InitLTSConnectionParameters(&paramters);
   paramters.handshakeCode = "handshakeCode"; // Please replace the handshakeCode with your own
   DBR_InitLicenseFromLTS(&paramters, errorBuf, 512);

Code snippet in C++:

   DM_LTSConnectionParameters ltspar;    
   reader.InitLTSConnectionParameters(&ltspar);
   ltspar.handshakeCode = "200***001-1000*****"; // Please replace the handshakeCode with your own
   iRet = reader.InitLicenseFromLTS(&ltspar,szErrorMsg,256);

Code snippet in C#:

   DMLTSConnectionParameters ltspar = _br.InitLTSConnectionParamters();           
   ltspar.HandshakeCode = "200***001-1000*****"; // Please replace the handshakeCode with your own
   EnumErrorCode iRet = BarcodeReader.InitLicenseFromLTS(ltspar, out strErrorMSG);

Code snippet in Java:

   BarcodeReader br = new BarcodeReader("")
   DMLTSConnectionParameters ltspar = br.initLTSConnectionParameters();
   ltspar.handshakeCode = "200***001-1000*****"; // Please replace the handshakeCode with your own
   ltspar.deploymentType = EnumDMDeploymentType.DM_DT_DESKTOP; // Please replace the deploymentType with your own
   br.initLicenseFromLTS(ltspar);

Code snippet in iOS (Objective-C):

   iDMLTSConnectionParameters* lts = [[iDMLTSConnectionParameters alloc] init];
   lts.handshakeCode = @"handshakeCode"; // Please replace the handshakeCode with your own
   _dbr = [[DynamsoftBarcodeReader alloc] initLicenseFromLTS:lts verificationDelegate:self];
- (void)LTSLicenseVerificationCallback:(bool)isSuccess error:(NSError * _Nullable)error
{
    NSNumber* boolNumber = [NSNumber numberWithBool:isSuccess];
    dispatch_async(dispatch_get_main_queue(), ^{
    [self->m_verificationReceiver performSelector:self->m_verificationCallback withObject:boolNumber withObject:error];
        NSLog(@"ifsuccess : %@",boolNumber);
        NSLog(@"error code: %ld:",(long)error.code);
        NSLog(@"errormsg : %@",error.userInfo);
        //UIImage *image =[UIImage imageNamed:@"AllSupportedBarcodeTypes.bmp"];
        //NSError* errormsg = nil;
        //NSArray* readResult = [_dbr decodeImage:image withTemplate:@"" error:&errormsg];
    });
}

Code snippet in Android:

   DBRLTSLicenseVerificationListener ltsListener = new DBRLTSLicenseVerificationListener() {
      @Override
      public void LTSLicenseVerificationCallback(boolean success, Exception error) {
      }
   };
   DMLTSConnectionParameters parameters = new DMLTSConnectionParameters();
   parameters.handshakeCode = "200***001-1000*****"; // Please replace the handshakeCode with your own
   dbr.initLicenseFromLTS(parameters,ltsListener);

If you run into any issues, please contact Dynamsoft Support.

This page is compatible for:

Version 7.5

Is this page helpful?

YesYes NoNo

In this article:

latest version

    • Latest Version
    • version 7.6
    • version 7.5
    Change +
    © 2003–2020 Dynamsoft. All rights reserved.
    Privacy Statement / Site Map / Home / Purchase / Support