03-06-2014 08:43 AM
Hi!
I am trying to manage panel close events and I am having some problems.
My program has a main event structure/while loop with several cases, one of which containing another event case/while loop.
I need to avoid the VI being closed if the inner structure is running, so I set a "Panel Close?" event with the Discard? enabled.
I need the VI to shut down properly if the outer structure is running, so I set a "Panel Close" event with a TRUE constant wired to the while loop condition.
The inner one seems to be working, while for the other one the program keeps running and the front panel is locked (but for the esternal "Panel Close" event I checked that the lock was not selected).
I attach a test version of this loops, it is a useless VI but the event structures work in the same way of the real program.
Thank you for your help!
03-06-2014 08:55 AM
Rule of thumb:
Never nest event structures.
Norbert