Developer Center Resources

cancel
Showing results for 
Search instead for 
Did you mean: 

Add Licensing Checks to an Application's Source Code

Note: This document has been archived. New applications/EXEs should use NI License Manager instead of the Third Party Licensing and Activation Toolkit. Please refer to Licensing Third-Party Products with the NI License Manager API for LabVIEW for updated guides.

Introduction

The Third Party Licensing & Activation (TPLA) Toolkit provides application developers a set of Licensing VIs that enable developers to perform Run-Time license checks and vary the behavior of the application accordingly.

You can use these VIs in your application's block diagram to create evaluation software and license your applications.

TPLA VIs.png

 

Example Flowchart

LicensedApplicationFlowchart.png


Example Code

The Third Party Licensing & Activation Toolkit installs an example that demonstrates how to perform a Run-Time license check.

LicensedApplicationExample.png

This example can be found here: [LabVIEW]\examples\addonlicensing\06 Sample Licensed Application

 


Related Links

« Back to Workflow: Creating Evaluation Software using Licensing & Activation

Jervin Justin
NI TestStand Product Manager
Comments
Thoric
Trusted Enthusiast Trusted Enthusiast
Trusted Enthusiast
on

I placed the Get License Status vi into my toolkit to query a license file for the status and rebuilt my vip package. When installed on a clean machine, the SoftwareKeyLicensingProvider.llb library was reported missing, specifically _SK_LicenseFileInfo.vi. Clearly I need to include some dependencies in my package definition, so what should I include and where should I place it to ensure there are no missing dependencies in my distribution? Do I need to include the whole of <vilib>:\AddonLicensing and have it placed in the destination <vi.lib> folder?

Thoric (CLA, CLED, CTD and LabVIEW Champion)


David_L
Active Participant
Active Participant
on

Interesting question.  For safety you can include all of the AddonLicensing llb from Vi.lib, or you can just pull in the specific VIs you need.  You will also need the licensing DLLs that the API calls into which are installed into LabVIEW\Resource and are SKCAXX.dll and KEYLIBXX.dll.  However if you are distributing your tool with VIPM, these dlls should already be installed as they ship with VIPM.

Thoric
Trusted Enthusiast Trusted Enthusiast
Trusted Enthusiast
on

Yes, I'm using VIPM to distribute. The dlls are indeed there but not AddonLicensing.llb. Because VIPM doesn't use the LV Project as it's source but instead a folder of files I would need to copy AddonLicensing.llb to my working folder to make it available to the package builder. I tried including TPLAT to the list of dependencies, but the install failed with error code 42 "Package Obsolete" - this from VIPM with full internet access, so why it didn't access the latest release I don't know.

Therefore, I think I'll try adding the dependencies to my toolkit manually, and place them in the appropriate vi.lib location. I'll get back to you when I've tried this...

Thoric (CLA, CLED, CTD and LabVIEW Champion)


David_L
Active Participant
Active Participant
on

The "Package obsolete" error is intentional.  We used to have a TPLAT package on the LabVIEW Tools Network repository, but it was many versions out of date.  We considered updating it, but decided as a team to not continue supporting this VIP dependency version of the code since 1) we couldn't guarantee a consistent update with new releases of TPLAT and 2) it might conflict with the actual toolkit installed from ni.com.  The best options are to either include the llb in your source code or to document a dependency on the NI toolkit as you would with other toolkits such as the Report Generation or Sound and Vibration toolkits.  Hope this helps.

Thoric
Trusted Enthusiast Trusted Enthusiast
Trusted Enthusiast
on

David_L wrote:


                       

The "Package obsolete" error is intentional.


                   

Oh, I see. This had me confused because in VI Package Manager the TPLAT toolkit is listed as V1.0.5.1 and there's no indication that this is obsolete, so there was no reason to believe it wasn't appropriate to make it a package dependency. It was only when I came to installing the compiled package that I was informed of the obsolesence. For the sake of an improved user experience, I think I'll try to directly include the library of code into the package and have it deposited into the appropriate installation folder.

Thanks David.

Thoric (CLA, CLED, CTD and LabVIEW Champion)


David_L
Active Participant
Active Participant
on

Well shoot.  I didn't even think to officially deprecate the package in the repository.  Fixed that now, but thanks for the heads up.  Let me know if you have any other problems with including the code directly...