02-17-2009 08:16 PM
Hi ppl, need help
I have an application which involves a lot of subvis and all need to be opened once set them to run, minimize or just disappear and give back control to main vi.
problems are:
1) since there are many subvis and all needed to be running , the laptop screen fills up and so , if minimized to taskbar it still is a problem to navigate with lots of subvis running, so, can the subvis be made like this-- pop-up when i click button on the main vi and then run/stop my sub vi manually and press button to disappear while it is still running in the background, If i wish to see it again It should be able to popup again when i press the same ok button on main vi.
Please see attached, just simple vis
the number on the main vi front panel should be still running after once i start the subvi and make it disappear
i tried with the suspend when called on subvi node setup, when i try to close the window, control is returned to main vi but it stops running and then exits.
anyway around this plzz
thanks
02-17-2009 08:19 PM
Sounds like you want the main program to control the appearance of the subVI, is that correct?
02-17-2009 08:22 PM
if the subvi still runs while invisible and i am able to pop it up back again by the main vi , it should do for me,
thanks
02-17-2009 08:29 PM
Here's a code snippet that should give you a good start.
The key is to get a reference to the subVI you want to minimize/maximize, and then use an invoke node to minimize/maximize it.
02-17-2009 09:49 PM
it is just minimizing it on the screen , still cannot make it invisible and appear by the main vi
i also tried to use the FP.state hidden property node but i am still lost.
02-18-2009 03:50 PM - edited 02-18-2009 03:52 PM
Hi freemason,
Try this Invoke Node:
02-18-2009 06:53 PM
This is part of the answer. The key thing to remember is that there is a difference between a front panel being open and one being visible. Using method in Smooter's code pass the enumerated value Hidden to the State terminal. This will open the front panel so the VI will continue running and stay resident in memory, but it will not be visible. The Activate input (if set to TRUE) simply makes the open windows foremost.
Mike...