LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

global still not work in compiled executables? V8.0

Jeez, I wish I had known that before I got to the compile stage Smiley Sad
Datasocket?
0 Kudos
Message 1 of 18
(2,918 Views)
Hi,
Are you having some problems with datasockets? It appears as though this post is referencing soemething else that I am not aware of.
Eric A.
National Instruments
Distributed I/O Product Support Engineer
0 Kudos
Message 2 of 18
(2,896 Views)
Sorry Eric, guess I was a little brief.  I was asking if I needed to use datasocket instead of globals to pass some variables.  Looked at that and shared variables.  My understanding of Labview is so incomplete that I'm having a hard time particularly as to interconnectivity and compiling.  I'll get something worked out eventually. Smiley Very Happy
0 Kudos
Message 3 of 18
(2,881 Views)
Here is the link people send me to whenever I ask about variables and interconnectivity. It may not specifically solve your problem (in that I don't know specifically what your problem is), but it's the process I followed to get my global variables to work in my compiled applications (and they do, indeed, seem to work).
0 Kudos
Message 4 of 18
(2,866 Views)
Thanks for that.  I believe my problem specifically is ignorance compounded by rampant stupidity. Smiley Very Happy
0 Kudos
Message 5 of 18
(2,860 Views)
Hi,
We'll try to help you figure out what is going on.  Tell us about what you are doing and and what data you are trying to transport.
Eric A.
National Instruments
Distributed I/O Product Support Engineer
0 Kudos
Message 6 of 18
(2,832 Views)

Thanks Eric.  I have figured out a lot with help from other people here on another thread.  What I want to do is to pass some data from one exe to another exe.  I am now doing this with a shared variable though originally I was using globals.  The shared variable is a 2 dimensional array set up as a custom control.  Using 8.5 I can compile and pass the array contents on my development computer between the two exe files in the project when I select 'network-published' as the variable type.  However, if I change the variable type to  'single-process' and re-compile it does not work.  Since my application will be installed on several computers on a network, I am worried that having the variable set up as network published will cause problems with other running copies of the program.  Each copy of the program will have a unique set of data in the array so it can't be shared.  Hope this makes sense.  I just need to determine if having the variable defined as network published will cause a problem and if it will, how I can make the program work properly using single process mode.
Thanks, Mike
0 Kudos
Message 7 of 18
(2,815 Views)
Hi Mike,
Shared variables used in multiple instances of the same executable on the same network can get pretty complicated.  I would suggest using TCP instead of shared variables because you can specify the computer you want to send data to.  Are the two executables that share data always going to be run on the same computer?
Eric A.
National Instruments
Distributed I/O Product Support Engineer
0 Kudos
Message 8 of 18
(2,796 Views)
Eric, yes the variables will only share between the two execuatbles on the same computer.  Thats what I understood the 'single-process' type was for.  But nothing I do will make the single process mode work when the programs are compiled. 
Thanks, Mike
0 Kudos
Message 9 of 18
(2,788 Views)
I'm not completely clear on what you're doing, but I think I might be doing something similar. That said, I have no idea how Shared Variables work, so I can't help you with that.

I'm doing it with an action engine that reads from and writes to a file on the hard drive. Since my code involves a "path to current vi" node, the .exe files will only be seeing data on the computer that they're on, and other users with similar programs running will not interfere.

I don't know if that helps you, but that's what I'm doing and it's working fine for me, so I thought I'd share.
0 Kudos
Message 10 of 18
(2,776 Views)