LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can a subVI tell when the application it is part of has been stopped and restarted?

Can a subVI tell when the application it is part of has been stopped and restarted?

It is easy enough for a subVI to tell when it has been run for the first time after having been loaded into memory. But is there a way for a subVI to tell when the application it is part of has been stopped and restarted? Is there some property or application-invocation-specific refnum that when queried multiple times during the same run of the application would return the same value yet when queried during different runs of the application would return different values?

I don�t want to depend on anything that happens when a run is exited.

I don�t want to require code to be included in the main V
I to accomplish the solution.
(Otherwise I could, in the main VI create an un-named semaphore tied to a global; the subVI could then check the global to see if the value changed, which it would between runs of the application.)

Any ideas?
0 Kudos
Message 1 of 3
(2,572 Views)
Have you tried the First Call? function? It's on the Advanced>Synchronization palette.
Message 2 of 3
(2,572 Views)
That would do it! Thanks!
0 Kudos
Message 3 of 3
(2,572 Views)