LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

import Network-Shared Variables in an executable

I'm trying to determine whether or not what I'm hoping to achieve is possible. Basically I have a bunch of tags defined in an NI OPC server on say machine A. What I then want to create is a standalone application (.exe) to run on machine B (on the same network) which is able to read the tags stored in the OPC sever on machine A. To do this, I am creating network-shared variables  via the project explorer GUI, that are bound to the host (m/c A) that can pick up the reuired data. This appears to work as I desire, however my issue is around creating and binding these variables programatically rather than graphically. What I want the exe to do is on startup, read a config file stored locally, within which the names of the tags to read are defined, then import these variables, creating NSVs in accordence with what is definedt and then finally bind them to the correct tags. In doing so the app becomes a generic mechanism which is not limited to having to be manually modified and rebuilt from the dev environment if the tags are changed/added/removed etc., instead everything is just defined base upon the config file. I'm not sure however if this can be achieved within the constraints of the SVE mechanism, is it the case that SVs must be defined/present in the project dev environment prior to building the app and as such cannot be created and bound to the remote OPC server programatically? Hopefully this essay makes some degree of sense, and thanks in advance!

OG
Research Engineer



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

Hi ogebler,

 

I have found some information thate hopefully can help you a little.

 

http://digital.ni.com/public.nsf/allkb/4757137A667431FD862572440008614E?OpenDocument 

 

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA03q000000YIDuCAO&l=en-US

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019RoKSAU&l=en-US

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019MFPSA2&l=en-US

 

I'm sory if they don't fit your requirements, but I'll be looking for a better answer Smiley Happy

 

Regards.

0 Kudos
Message 2 of 2
(2,371 Views)