LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Programmatically choose boolean to write in cluster

Solved!
Go to solution

If only one button should be active, use a radiobutton control instead.

0 Kudos
Message 11 of 15
(166 Views)

What about this?

Yamaeda_0-1739521428192.png

(It's more 'appropriate' to use Array to cluster after the replace, but then you must know and set the cluster size)

Yamaeda_1-1739521550439.png

 

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 12 of 15
(153 Views)
Solution
Accepted by topic author SydneyAVDE

@SydneyAVDE wrote:

As said before, today i will upload the code. Here it is. (saved in v20.0)

Functionality: only 1 button may be active, print last activated labelname into string.

 

I am sure this could be way more efficient. 


Here's how it could look like using a radiobutton control (that's just a container for booleans where exactly one is true and the value is an enum with the label of the control. It can also be configured to allow "no selection" if needed).

 

Your blatant overuse of local variables blurs the distinction between control and indicator. Both strings should be indicators! Right?

 

Your keyboard keys are latch action, so they reset once read by the code (but the terminal must be inside its event structure!)

 

altenbach_0-1739552224419.png

 

altenbach_1-1739552592982.png

 

 

Message 13 of 15
(129 Views)

I had no idea you could modify the controls in a radiobutton control.

Message 14 of 15
(66 Views)

@SydneyAVDE wrote:

I had no idea you could modify the controls in a radiobutton control.


You can customize a great many things in LV if you look around. Here's some examples.

Awesome GUI Design Examples - LAVA Lounge - LAVA

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 15 of 15
(56 Views)