Company Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Binding Shared Variables to an Existing Source

LabVIEW 2010 Help

Edition Date: June 2010

Part Number: 371361G-01

»View Product Info

You can bind shared variables to NI Publish-Subscribe Protocol (NI-PSP) data items on the network or to existing shared variables by placing a checkmark in the Enable Aliasing checkbox on the Variable page of the Shared Variable Properties dialog box. You can bind only network-published shared variables.

Note  You can create, configure, and host shared variables only on Windows or RT targets with the LabVIEW Real Time Module. You can use the DataSocket VI and functions to read or write shared variables from other platforms.

Binding a shared variable to a shared variable in another project or to an NI-PSP data item allows you to incorporate values from other projects and the network into the active project. To register a computer that is not on the local subnet, select Tools»Shared Variable»Register Computer. You can specify the computer name or the IP address of the computer. You then can bind a shared variable to the computer.

Complete the following steps to bind a shared variable to a shared variable in another project or to an NI-PSP data item.

Note  You can bind shared variables only to shared variables in other projects and data items that are currently deployed.
  1. Create a shared variable or right-click a shared variable in the Project Explorer window and select Properties from the shortcut menu to display the Shared Variable Properties dialog box.
  2. Place a checkmark in the Enable Aliasing checkbox.
  3. Select PSP URL or Project Variable from the Bind to list.
  4. In the Path text box, enter a network path to the shared variable or data item to which you want to bind, or click the Browse button to display the Browse for Variable dialog box.
  5. If you display the Browse for Variable dialog box, navigate to the shared variable or data item to which you want to bind.
  6. Click the OK button.

Binding a shared variable to an existing shared variable in the active project allows you to view the values separately. For example, you might bind a shared variable to a shared variable that exists in another folder or project library within the active project to create a simplified view of the data. Complete the following steps to bind a shared variable to an existing shared variable in the active project.

  1. Create a shared variable or right-click a shared variable in the Project Explorer window and select Properties from the shortcut menu to display the Shared Variable Properties dialog box.
  2. Place a checkmark in the Enable Aliasing checkbox.
  3. Click the Browse button to display the Browse for Variable dialog box.
  4. Navigate to the shared variable to which you want to bind.
  5. Click the OK button to return to the Shared Variable Properties dialog box.
  6. Click the OK button.

 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit