LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Directory of Shared Variables not changing

I am having trouble programmatically deploying my shared variables on a different host computer with an executable. The production PC does not have LabVIEW installed but has all the other required installers to run the executable. The shared variables deploy since I selected the option to deploy when the application runs under the build specifications. Though when they deploy, the shared variables keep the same directory as my development computer. So what I have been doing is going into Distributed System Manager on the new host computer and manually changing the path of the variables. This works fine until I have to stop the executable and run it again to which the variables go back to their original path and I have to change them manually again. I have looked up ways to fix this such as changing the .aliases file as mention in these steps. I have also tried the invoke node method suggested here but still have not had any success in that.  I will continue researching ways to accomplish this but if anyone could help me out I would greatly appreciate it.

 

Thanks

0 Kudos
Message 1 of 2
(1,882 Views)

I read, at the beginning of the tutorial, that "A shared variable is accessible through a network, but hosted on a single machine. When developing your VI in LabVIEW, the shared variable library is automatically deployed to the target it is listed under in the project explorer. When the library is deployed to this target, that target is now "hosting" the shared variables contained in the library. Other computers will have to connect to this target to read or write the shared variable library."

So, in theory, you need to first be able to ping your development PC (PC1) from your production PC (PC2). Then change the .aliases so each computer appears with its correct IP address, then the application, when it needs to call the Shared Variable (ShV) from the PC2, it will first search for the PC1 alias's IP, and then it will search in that computer's directory for the ShV and then it should deploy the ShV to the PC2.

I am not that familiar with the Distributed System Manager but since your executable works fine with it when you manually change the ShV's path UNTIL you stop the executable, it makes me think that stopping the executable undeploys the ShV and then you have to set it up again. But this is only a theory.

Can you try making sure that you have this checkbox un-checked?

0 Kudos
Message 2 of 2
(1,829 Views)