10-16-2014 07:58 AM
Hi
I'm using a code with occurances and I went to the examples to learn how they work. However, I added one extra while loop and the VI needs to press two times the stop button to go out of the loops. Is any explanation for this ? I suppose after pressing stop the condition becomes TRUE and the outer loop should stop immediately. I attach the modified VI
Thanks
Solved! Go to Solution.
10-16-2014 08:14 AM
There is a very good reason. I suggest you turn on highlight execution and see what it is!
Hint: look at the value of your "Loop Stop" global variable right after you hit "Stop" the first time.
10-16-2014 08:35 AM
That's true. With the highlighting it is apparent that needs two times. But still I cannot get the point when Global Varible becomes True but the while loop continues for one more time the Outerloop. And then it's obvious that Stop should be pressed again to go out from Loop1 and 2.
10-16-2014 08:52 AM
Get rid of the global variable that is wired to the conditional terminal. Wire from the True in the flat sequence structure directly to the conditional terminal.