LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

keeping a section of code from running

Hey gang! I've coded myself into a corner and am looking for a way out. The "Auto Barrel" local variable has information written to it earlier in the case structure and that information is passed out of the event structure once the while loop that contains it ends. This is normally an excellent thing. However, my problem is that I have added a "cancel" button to the program that once pressed, has a confirmation dialogue asking the user if they are certain they don't want to add a barrel. My problem is that even if "Yes" is pressed, the while loop still ends up passing the information contained in Auto Barrel on which, in this program, means that the cancel button doesn't actually cancel anything as the information is already in "Auto Barrel" and is passed on once the cancel button ends the loop.
 
 
 
 
I am fully aware that this code is doing exactly what it should do, but how can I get the cancel button to keep "Auto Barrel" from passing the information along? This section of code is run more than once and all of my solutions so far work for one interation, then it fail. Thanks folks! And Happy Pi Day to my fellow geeks!
 
-- Jason
0 Kudos
Message 1 of 3
(3,014 Views)

Hi Jason,

this picture looks pretty suspicious to me. Are you sure you posted your question on the right forum Smiley Wink

0 Kudos
Message 2 of 3
(3,013 Views)
Arrgh! I can't believe I did that. Mods please delete this thread! Apologies!
 
-- Jason
0 Kudos
Message 3 of 3
(3,006 Views)