Error -1950678968 When Trying to Deploy or Run a Program that Uses Shared Variables on My Real-Time Target

Updated Apr 21, 2023

Reported In

Hardware

  • CompactRIO Controller

Software

  • LabVIEW
  • LabVIEW Real-Time Module

Driver

  • NI-RIO

Issue Details

After creating a program for my real-time target, I get errors related to ni_tagger when I try to run or deploy my VI. The error message states
 

Failed to download ni_tagger_lv_Write.vi LabVIEW: Failed to load shared library nitaglv.dll.
 

or
 

Error -1950678968 occurred at Shared Variable in <VI name>.vi. Possible reason(s): LabVIEW: Failed to load nitaglv, which is required for Network Published Shared Variables.
 

What does this mean, and how do I fix it?

Solution

When using Shared Variables on a real-time target, it is necessary to first install the Shared Variable software components. If you do not, you will be prompted with the above error when you try to run your real-time program.

There are two components to the Shared Variable Engine for real-time targets: the Network Variable Engine and Variable Client Support. The Network Variable Engine must be installed on the real-time target if you wish to host shared variables on your real-time target. The Variable Client Support component must be installed if you wish to access Shared Variables hosted on a different machine (real-time or Windows). 

To install these components,
  1. Open Measurement & Automation Explorer (NI MAX). 
  2. Find your real-time target under Remote Systems
  3. Expand your real-time target and right-click Software
  4. Select Add/Remove Software
  5. Install the shared variable components (Network Variable Engine and Variable Client Support). 

If you do have the Shared Variable Engine and Shared Variable Client installed onto your Real-Time target, you may be running into a memory issue. You can resolve this by formatting and performing the minimum installation onto your target. For instance, with a CompactRIO you would only install the NI CompactRIO software stack as shown below (making sure to not add any software besides the Network Variable Engine and the Variable Client Support as shown above):

If the format and re-installation of minimum software does not resolve the issue, there may be something with your LabVIEW program that is causing memory problems. You can monitor memory usage or start from scratch with a new project, adding small elements of your code at a time.