LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamically close VI

We can dynamically open VIs with VI server....Is there a way to dynamically close the whole VI (not just the front panel)?

Background: I have a computer running a whole bunch of VIs that are loaded dynamically from a common server. One of those VI's can change on the server and now the computer is running an outdated VI....

Currently I have to stop LabVIEW and restart the VI that loads everything. This can be a hassle, and there might be VI's that I can't bring down.

Ideally I would like to show a list of all VI's in memory and then individually select VI's to close. I can then relauch them through VI server.

Any ideas...

Eldon

[Using LabVIEW 6.1]
0 Kudos
Message 1 of 4
(3,374 Views)
You should be able to allow the vi to be removed from memory by closing its
reference. Is this the part that's not working?

Just to be clear, my understanding is that you have several vi's on disk
which you load dynamically using the vi server. The vi's are not sub-vi's
of another vi. Are you using the invoke node to run the vi's or are you
using the call-by-reference function?

"Eldon Skousen" wrote in message
news:50650000000800000004AE0000-1066448259000@exchange.ni.com...
> We can dynamically open VIs with VI server....Is there a way to
> dynamically close the whole VI (not just the front panel)?
>
> Background: I have a computer running a whole bunch of VIs that are
> loaded dynamically from a common server. One of those VI's can change
> on the serve
r and now the computer is running an outdated VI....
>
> Currently I have to stop LabVIEW and restart the VI that loads
> everything. This can be a hassle, and there might be VI's that I
> can't bring down.
>
> Ideally I would like to show a list of all VI's in memory and then
> individually select VI's to close. I can then relauch them through VI
> server.
>
> Any ideas...
>
> Eldon
>
> [Using LabVIEW 6.1]
0 Kudos
Message 2 of 4
(3,374 Views)
In article <50650000000800000004AE0000-1066448259000@exchange.ni.com>,
"Eldon Skousen" wrote:

> We can dynamically open VIs with VI server....Is there a way to
> dynamically close the whole VI (not just the front panel)?

What I do when dynamically calling reentrant VIs is use the rendezvous
library to let me know when the vi has finished (can't use FP with
reentrant vis). This way I can load thousands of them into memory and not
worry about closing the ref at the wrong time, like while the vi is
running.

That may be useless advice if none of your vis are reentrant. Sounds like
in your case, you should just follow DD's instructions by closing the vi
ref after you close the front panel. If you're having trouble keeping
track of your refs, just us
e globals. Let us know if we misunderstand
your problem.
0 Kudos
Message 3 of 4
(3,374 Views)
Extract the VIs to the same folder.

Run the main VI.
SubVI can be called or closed from within the main VI.
Ian F
Since LabVIEW 5.1... 7.1.1... 2009, 2010, 2014
依恩与LabVIEW
LVVILIB.blogspot.com
0 Kudos
Message 4 of 4
(3,374 Views)