LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Stopping while loops running in parallel with a single boolean without using local variables

I would use a functional global/action engine.

PaulG.
Retired
0 Kudos
Message 11 of 12
(827 Views)

Ray.R wrote:

 

Only if you kill the Queue <BEFORE> the bottom loop reads from the queue.

Although you click stop and it will stop the loop, it will still enqueue the True value, which is then read from the bottom loop.

 

A trick is to kill the queue at the exit of the bottom loop.

 


 

Oops..  Sorry.. I mean Notifier.

Thanks Jim.

 

And thanks Paul. 

Yes, Functional Globals/Action Engines are a good way of implementing the solution, especially if the loops contain lots of code and you may also want to stop the top loop if something happens in the bottom loop.  OR...  If you have multiple loops with inter-dependencies that you want to stop if something happens to any of the loops.

 

R

Message Edited by Ray.R on 03-13-2009 08:43 AM
Message 12 of 12
(824 Views)