LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Resize Radio Buttons?

Solved!
Go to solution
Solution
Accepted by topic author RTSLVU

@mcduff wrote:

I seriously did not see your ancient code,


I doubt I ever posted the old code, but here's how your code would look leveraging radiobuttons. 😄

Arguably simpler... And they even work in edit mode. 😮

(note that I made the container transparent)

 

 

FancyRadio.png

Message 11 of 31
(3,501 Views)

@altenbach wrote:

@mcduff wrote:

I seriously did not see your ancient code,


I doubt I ever posted the old code, but here's how your code would look leveraging radiobuttons. 😄

Arguably simpler... And they even work in edit mode. 😮

(note that I made the container transparent)

 

 

FancyRadio.png


How did you change the buttons?

 

For the life of me I messed around with the Radio Button control and could not change anything besides the text.

 

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 12 of 31
(3,491 Views)

@altenbach wrote:

I guess I don't understand the question. A radiobutton control is just a special container for booleans (any type, flavor, amount) with some logic that only the last pressed is true.

The type is an enum containing the labels of the Boolean as item names. The value is the current selection.

 

Like clusters, you can arrange the elements any way you want (turn off autosizing, arrange horizontally, etc.)

 

Yes, before radiobuttons, we had to make our own logic. (Still need that for special versions. I have one where the last two are true ;))

 

(Posting by phone, cannot test you snippet)

 

(And please vote for this old idea :))


OMG shoot me now. I never realized you could just drag booleans in and out of it.

========================
=== Engineer Ambiguously ===
========================
Message 13 of 31
(3,485 Views)

I also continue to Learn and Be Amazed by Altenbach -- his "Design Your Own Radio Button" observation of a Feature that NI built into this Boolean Control is simply amazing, and totally new to me.  I'm now embarrassed to have my post to this question marked as a "Solution" -- Altenbach's Method is far superior, and I plan to try it out in my Project that I described a few posts ago.

 

Bob "Still Learning" Schor

Message 14 of 31
(3,470 Views)

592d63fd4c7ae_SegmentedControl.png.599aa30daeb40faa1120c8b441f07b74.png

 The "Segmented control" from Flatline Controls is also just a modified radio button with heavily-customized system Boolean controls.

0 Kudos
Message 15 of 31
(3,432 Views)

@Kyle97330 wrote:

Alternately, you could use a tab control with the actual bit of the tab you'd normally put things in resized to zero height.  It would eliminate the need to have actual code running that turns off any other Boolean that's part of the cluster that's already on.  Not perfect, but it might be simpler.


See my tag cloud for " I hate Tabs "  there is a beauty of an example replacing a Tab Container with a custom radio button and a sub panel. 

 By far more maintainable than A single vi with a "Tabasaurus Wrecks" front panel.  Modular and configurable too.  Just change the text on the radio button and link to a new vi or vi version to drop in the sub panel.  Main UI doesn't have to change a byte to extend features!

 

Via phone.  Kudos for links y'all 

 


"Should be" isn't "Is" -Jay
0 Kudos
Message 16 of 31
(3,428 Views)

@Jeff B

 

https://forums.ni.com/t5/LabVIEW/tab-in-control/m-p/1869263/highlight/true#M633569

 

https://forums.ni.com/t5/tag/IHateTabs/tg-p/board-id/170

 

No need for kudos Jeff, next time I flash the Jeff B DAQmx sign, just be listening. 🙂

 

mcduff

Message 17 of 31
(3,424 Views)

Kudos anyway 


"Should be" isn't "Is" -Jay
0 Kudos
Message 18 of 31
(3,422 Views)

Reduced to the basics, a tab control is basically just a horizontal radio button control with a dedicated area where each state can have an associated set of unique FP elements relevant to just that state. Nothing wrong with that. 😄

0 Kudos
Message 19 of 31
(3,417 Views)

@altenbach

@altenbach wrote:

Reduced to the basics, a tab control is basically just a horizontal radio button control with a dedicated area where each state can have an associated set of unique FP elements relevant to just that state. Nothing wrong with that. 😄



 wrote:

Reduced to the basics, a tab control is basically just a horizontal radio button control with a dedicated area where each state can have an associated set of unique FP elements relevant to just that state. Nothing wrong with that. 😄


Except that we associated related controls by logical groups and then smushed all the code for those separate groups on 1 block diagram.   I Hate Tabs.  They are the Stacked Sequence Structures of the Front panel. 

 

I'm not going to argue the appropriate use of either. :D. Will you?


"Should be" isn't "Is" -Jay
0 Kudos
Message 20 of 31
(3,398 Views)