LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Controlling vertical control bar's property during runtime

Hello,

I'm really new to labview and I want to change the color of the vertical bar during runtime depending on certain conditions. Any help is welcomed. Thanks in advance.

Cheers
0 Kudos
Message 1 of 5
(2,768 Views)
I am not aware of any control or indicator name "Vertical Bar", could you a bit more specific?

(Are you talking about a "vertical progress bar", a vertical cursor on a graph, etc?)

In General, you would create a property node and wire the desired color constant to it. The attached example programmatically changes the color of a vertical progress bar.
0 Kudos
Message 2 of 5
(2,764 Views)
Hi,

You can find the vertical progress bar control under "numeric" . I have tried using property node as you recommended. It works good. But I do not know how to get rid of the other properties from view which i do not need to change during runtime. I try to delete it, but it disappears forever and i fear next time if I need to change other properties, i'll be in trouble.


As can be seen, I actually only need to control 3 properties at the moment.

Thank you for your help.
0 Kudos
Message 3 of 5
(2,762 Views)
The property node is extremely flexible, and you can't get into any trouble by deleting items, because they are easy to add back (see below) if necessary. Note that there is initially always only one item listed after you right-click on a control and choose Create >> Property Node.

Then:

- You can add an arbitrary number of property items by "resizing" the node with the positioning tool or by right-clicking and choosing Add Element.
- An item can be changed to any available property by right-clicking and choosing Properties >> [property]. Or, you can use the Operate tool (the pointing-finger) and left-click to get the same property list.
- You can delete a bunch of items at a time by resizing, though you are prevented from killing an already-wired item this way, and must unwire it first. Alternatively, you can always right-click and choose Remove Element with a single item.

If I were in your shoes and had created a long list of items and only needed to set three things, then I would probably either unwire-and-resize, then rewire, or I would just delete everything and create a new node from scratch with only three items.

--John
Message 4 of 5
(2,748 Views)
You only need to expand the property node to show the number of properties that you actually need. Then you left-click on each property and select what you want. For example to change only the fill color, make a size one property node and select "fill color". 🙂 (See image).
Message 5 of 5
(2,747 Views)