12-16-2021 10:11 AM
Hi everyone,
I hope someone can help me. I want to change the value of the cluster controls programmatically. Normally I go over Property Node -> Value -> Change To Write -> Create Constant, where I can set my new values (FIG 1).
But there is a case, where I cannot do it. The Value gets a violet colour and there are no constants shown as normally. Could you please help we with that? An image is attached.
Thank you,
Jani
12-16-2021 10:21 AM
Give the cluster elements unique names. Then you can get a property value node to "Cluster.ElementName"
12-17-2021 11:23 AM
Attach your code, not a picture.
12-17-2021 11:33 AM
The violet color means that it's a variant. Without seeing the code (just a simple VI containing the two cluster is all we need!) we cannot tell you why that is. There could be many reasons.
12-17-2021 03:05 PM
@altenbach wrote:
The violet color means that it's a variant. Without seeing the code (just a simple VI containing the two cluster is all we need!) we cannot tell you why that is. There could be many reasons.
The picture tells a lot. Cluster 2 is typedefed. We can see the black glyph in the constant top left and no Coercion dot. So, we want the ctl file too to get the whole story.
Axis control Cluster is an empty cluster (archsesteurung is German) we can tell from the black type bar in the node. Oddly, the created constant of an empty cluster and any property value nodes are of type variant not type empty cluster. (Actually, that does make a weird kind of sense since VOID var is the only sane value)
Likely, the new ctl has unapplied changes or hasn't been edited to add the ( assumed Xpos, Xpos and boolean option elements)
12-17-2021 05:04 PM
@JÞB wrote:
The picture tells a lot. Cluster 2 is typedefed. We can see the black glyph in the constant top left and no Coercion dot. So, we want the ctl file too to get the whole story.
The OP did not have a problem with cluster 2, so we don't really care about that. The problem is with the one on the right and most likely you are right with the empty cluster theory. The question is why is it empty? That alone would break the code, of course. I was assuming that the code was otherwise runnable.
Unfortunately I was probably wrong with my assumptions regarding the LabVIEW skills of the OP. 🙂
12-17-2021 06:53 PM
@altenbach wrote:
@JÞB wrote:
The picture tells a lot. Cluster 2 is typedefed. We can see the black glyph in the constant top left and no Coercion dot. So, we want the ctl file too to get the whole story.
The question is why is it empty? That alone would break the code, of course. I was assuming that the code was otherwise runnable.
With that Black type bar in the property node, the code has a broken run arrow without a doubt.