01-16-2013 05:24 AM
If I show a decoration's Object Property dialog, a field named "Label" appears where I can type text in (LV2011). There's also a "Visible" check box above it.
However, the check box keeps to be disabled even if I put some text in the label, furthermore the text is not retained when I close the dialog.
On the other side, a decoration property node will not show any "Label" item.
What this field is good for?
Solved! Go to Solution.
01-16-2013 05:29 AM
pincpanter wrote:What this field is good for?
Probably nothing. The Decoration class, if memory serves, inherits from Generic, which does not have a Label property. I'm guessing this is just an oversight in the dialog where no one thought to hide that field. I didn't even notice that you can open the properties dialog for a decoration.
01-16-2013 05:37 AM
That's a pity. I did hope to use that Label to identify decorations. Indexing the Decorations[] array it's uncomfortable and prone to errors.
01-16-2013 07:21 PM
01-17-2013 10:40 AM
Thanks for the links. In the meantime, I have written a "decoration managing" vi that may be useful to show decoration indexes and easily hide/show them.
BTW: for a label decoration the Label field matches the decoration text.
01-17-2013 02:59 PM
Just put a floating label next to the decoration, then group them.
01-18-2013 01:57 AM
What I would like to do is to show/hide and possibly move decoration programmatically. For this, I need to know the position (index) of each decoration in the Decorations[] reference array.
That index may change when you move objects forward or backward in the FP. Hence the need of a method to find the index quickly.
01-18-2013 03:56 AM
I would assume the index doesn't change, but i haven't tested it. Z-property doesn't change index of controls, to my knowledge, only tab-order.
/Y
01-18-2013 04:12 AM
Yamaeda ha scritto:
I would assume the index doesn't change, but i haven't tested it. Z-property doesn't change index of controls, to my knowledge, only tab-order.
/Y
The index does change indeed following the Z order. You may check it quickly using my vi.
01-18-2013 04:28 AM
Hmm, what if you turn the decoration references to Variants and add use Set Attribute? Then you have something to search for.
/Y