LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why does label not dim when cluster is disabled?

LabVIEW 7.0, Win 2k.

I have attached a small VI which illustrates what I think is incorrect behavior.

I put two instances of the same cluster typedef (strict or not - it doesn't matter) on a panel.

I disconnected one instance, just to prove a point.

If you disable and gray the clusters, the one which is still connected to its typedef will dim but its label will NOT.

The one which has been disconnected properly dims the label too.

Why?

Can I work around it?
Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


LinkedIn

Blog for (mostly LabVIEW) programmers: Tips And Tricks

Message 1 of 14
(5,027 Views)
Interesting.

It does the same on 7.1.1 on XPPro.

I don't see any easy workaround. The Captions behave the same.

Ed


Ed Dickens - Certified LabVIEW Architect
Lockheed Martin Space
Using the Abort button to stop your VI is like using a tree to stop your car. It works, but there may be consequences.
0 Kudos
Message 2 of 14
(5,022 Views)
Maybe as a workaround you could make the label invisible when you disable&gray the control.

Looks a little strange with the label disappearing and reappearing though.

Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 3 of 14
(4,999 Views)
A better solution, inspired by Ray, is to change the property Label.FontColor.

___________________
Try to take over the world!
Message 4 of 14
(5,000 Views)
Or maybe just add a "Simple String Indicator" (look in the Classic Controls>String palette) with no border and a transperent background to your cluster as your "Label".

Ed


Ed Dickens - Certified LabVIEW Architect
Lockheed Martin Space
Using the Abort button to stop your VI is like using a tree to stop your car. It works, but there may be consequences.
0 Kudos
Message 5 of 14
(4,994 Views)
That sounds to be the best workaround.

Ray
Regards
Ray Farmer
0 Kudos
Message 6 of 14
(4,967 Views)
It would have to be a control instead of an indicator in my case - the cluster is a control.
I suppose I could disable it.

The trouble with that is that I don't want to change the structure just to add a phony label element.
Yeah, I could re-process the dozens of files I have, to add this string into a cluster, but does it really have to be such a Son of Ugly Hack?
Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


LinkedIn

Blog for (mostly LabVIEW) programmers: Tips And Tricks

Message 7 of 14
(4,963 Views)


@CoastalMaineBird wrote:
Yeah, I could re-process the dozens of files I have, to add this string into a cluster, but does it really have to be such a Son of Ugly Hack?


Not if you use my suggestion. Since you're using a property node anyway, you just need to add that property and select the appropiate color. You will also need to change it only where you disable.

___________________
Try to take over the world!
0 Kudos
Message 8 of 14
(4,948 Views)
Since you're using a property node anyway, you just need to add that property and select the appropiate color.


Yeah, yours is the best workaround I've seen.
It's still less independent than I'd like (If I change the label's color, I have to change these constants).
Also, sometimes there are different shades, depending on how many layers are disabled (If its container is disabled as well, a cluster's label can be doubly-dimmed, though I don't think that applies in my case.)

Still, it's either that or ugly.

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 9 of 14
(4,943 Views)

Yeah, I could re-process the dozens of files I have, to add this string into a cluster, but does it really have to be such a Son of Ugly Hack?
If you're using the same cluster in several different places, you should look into making it a "type def" control. That way, if you need to make a change to the structure, all you have to do is open the type def control file, modify it and it and all the linked control get updated automatically.

But if you didn't do that, TST's idea of just changing the color is probably the easiest. As long as you can figure out the roght color.

Ed


Ed Dickens - Certified LabVIEW Architect
Lockheed Martin Space
Using the Abort button to stop your VI is like using a tree to stop your car. It works, but there may be consequences.
0 Kudos
Message 10 of 14
(4,929 Views)