04-18-2015 11:55 AM
In the main program during execution when appropriate button is clicked subvi with a picture is called (chosen by case structure). The rest of the program (front panel) is blocked until the subvi window is closed - how can I open the subvi with a picture so it remains opened and the program goes further?
greetings,
Michal
Solved! Go to Solution.
04-18-2015 12:08 PM
What does your code look like?
]When a subVI is called, the rest of the code in the line of execution isn't going to run until the subVI returns. So is this subVI something like a separate front panel with a loop that you want to run in parallel with the rest of your main VI? If so, you either need to call it in a way that doesn't block the rest of your code, or use the Asynchronous Call by Reference method.
04-18-2015 12:15 PM
Thanks for quick response! That subVI returns nothing it is kind of additional window that presents the thermogram with chosen points. Yes it is a subVI in a while loop - it closes after stop condition (click on the stop button). Can you briefly explain how to use Asynchronous Call by Reference method so i can set some input to that subVI?
04-18-2015 12:16 PM
04-18-2015 12:18 PM
Search in the example finder for "asyncrhonous". The Asyncrhonous Call and Forget.VI would be a good example for you.
04-18-2015 12:35 PM - edited 04-18-2015 12:36 PM
I've done it exactly as in the example, thanks - but still the main front panel is blocked.. should I get rid of while loop in subVI? how closing it should be handled then?
04-18-2015 12:39 PM
Please attach the main VI.
04-18-2015 12:41 PM
is it enough for you or u need entire project?
04-18-2015 12:52 PM
You forgot the Call and Forget setting (0x80) in the Open VI Reference. Look again at the Example ...
Bob Schor
04-18-2015 02:12 PM - edited 04-18-2015 02:15 PM
I added the setting (x80) (copied it form example) but it is still blocking the further execution of the main VI until subVI is closed..