Archived:Unlicensed WPF Control Error with Measurement Studio 2015 and Visual Studio 2015

Updated Sep 15, 2023

NI does not actively maintain this document.

This content provides support for older products and technology, so you may notice outdated links or obsolete information about operating systems or other relevant products.

Reported In

Software

  • Measurement Studio

Issue Details

I am using Measurement Studio 2015 with Visual Studio 2015. When I use the WPF controls such as the Arrow Button, Switch, and Slider double in Measurement Studio I get the following error: 

"NationalInstruments.Controls.Internal.WpfStandardLicenser" is unlicensed. 

How can I fix this error?

Solution

This is a licensing issue specific to Windows Presentation Foundation (WPF) controls. Since Measurement Studio 2015 does not have integration features for Visual Studio 2015, this means that controls are not in the toolbox and the .licx file is not automatically generated. Follow these steps to license the WPF controls:
  1. Check in NI License Manager so that you have an activated version of NI Measurement Studio. If it is fully activated it will have a green colored box next to the license.​​​
  1. Create the .licx file to manually license the Measurement Studio assembly. Use a text editor to create an empty text file and name the file “licenses.licx” and place it in the same folder as your project.
  2. Drag the licenses.licx file from your file explorer into your project
  3. Right-click the licenses.licx file and click on Include in Project. If you have the option to Exclude from Project, it is already properly included in the project.
  4. Click on the licenses.licx and go to the File Properties and make sure that the Build Action is set to Embedded Resource.
  5. Open up the licenses.licx file where you will have to create the entries.
    • There is a WPF example of a licenses.licx file found in the Creating an .licx File Without Visual Studio-Integrated Tools section of the Measurement Studio help. The version of the assembly and the PublicKeyToken will need to be changed to reflect the assembly version and characteristics on your computer.
    • The license can also be auto generated using the following generator: Create a .licx File for My Measurement Studio Project.
  6. If the previous steps do not help in fixing the issue, try repairing the Measurement Studio installation. 

Additional Information

To do add the Measurement Studio 2015 WPF User Interface Controls to the toolbox look at the following article: Using Measurement Studio 2015 with Microsoft Visual Studio 2015 .