LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Control names load from file

Solved!
Go to solution

Is there a way to load a control (i.e. boolean switch) name from a file?

 

Here is my situation. I have 4 selector toggles, and a go button. Picking a selection and pressing go will send an array of four binary numbers (true or false converted to 0 or 1) to a sub vi called command_former.

 

This program is simple. It first loads up a library file with pre-made sequences of bytes which correspond to each button. It outputs an array that includes the appropriate byte sequences concatenated onto one another if the selector toggle is set to 1.

 

By loading the values from a file, it easily lets the user change what the selector toggles do. But I do not know how to change the name to also load from a file.

0 Kudos
Message 1 of 3
(2,044 Views)
Solution
Accepted by topic author Macarthskey

You cannot change the name of a control at run-time. You can, however, change the caption. For Boolean controls if you want to change the text that appears in the middle of the control this is done via the BooleanText property node. See https://decibel.ni.com/content/docs/DOC-22669 for a simple example.

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

That is too bad. But I suppose it doesnt matter either; I dont see any harm in just nameing the switches 0:3.

 

The captions will work. Thanks.

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