LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Auto-sizing boolean text within a fixed size button control in labview.

I am trying to make my own pop-up confirmation window that you can pass in text to display on the selection buttons. These buttons have to remain a fixed size/position but they also have to display up to a five word statement. I have been trying to modify the characteristics of the buttons and the text using the Property Nodes with no luck. Is there an example in LV?...or if someone has done this, I would appreciated any help.

Thank You
0 Kudos
Message 1 of 3
(4,019 Views)
You cannot change the LABEL of a button under program control, but you can change the CAPTION.

Hide the label, and show the caption.
Stretch the caption rectangle to fill the button left to right, and set it's JUSTIFY to CENTER.

Set whatever font properties you like.

Then use the property node to set the CAPTION - TEXT to whatever it needs to be at run time.
Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


LinkedIn

Blog for (mostly LabVIEW) programmers: Tips And Tricks

0 Kudos
Message 2 of 3
(4,016 Views)
As you have discovered, by default, buttons will autosize if the boolean text in them gets too big. You can disable this behavior by popping up on the button and selecting “Release Text”. I am not sure if there is an equivalent property. You can try “Lock Boolean Text In Center”. Good luck!
Message 3 of 3
(3,996 Views)