From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to cause sub-VI's to become unchangeable after interaction?

 

My current project is based on a Tic Tac Toe Human vs Human project. I have the basic set up of the gameplay but have a issues in two main areas.

1. How do I set it so that once a button is pressed, it cannot be unpressed. Effectively locking it in place and the resulting value being sent only once place as well.

2. How  can I have new infomation come into a while loop while an internal loop is continuing.

I will attach the files to better demonstrate point 2.

 

Basically my Boolean switch sends its T/F data to a while loop where the data remains, constantly looping. I want the while loop to send the T/F data to the indicator and then loop the button again. 

Any help would be apprecaited. 

0 Kudos
Message 1 of 3
(2,009 Views)

You can use a Property Node for the control called disabled.  Create the enum constant from it and set it to disabled.

 

Check your main while loop condition.  You have a stop button wired to it, but it is set to Continue if True, not Stop if True.  So the logic is backwards.

0 Kudos
Message 2 of 3
(2,000 Views)

I would highly recommend you look into using the Event Structure.  That way you react to button presses and value changes instead of polling the values constantly.  Your CPU will thank you.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 3 of 3
(1,956 Views)