Showing results for 
Search instead for 
Did you mean: 

Subvi reopening issues

I open a subvi by clicking a button in the main vi. When I open it for the first time, the front panel controls are empty as I expect them. After completing the subvi it closes and vanishes. I donot save anything explicitly. However, when I open the subvi again from the main vi, without exiting from the main vi, it opens in the state I closed it the last time I used it. Is there something I have to do programmatically to reset the controls before closing the subvi? 

Thank you. 


0 Kudos
Message 1 of 2

Because your sub VI is a dependency of the main VI, it remains in memory as long as the main VI is in memory.  Thus, even though the sub VI's front panel closes, it is still in memory, and retains its state, including the values of the controls.

You probable want to use this:




"If you weren't supposed to push it, it wouldn't be a button."
0 Kudos
Message 2 of 2