LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

XControl "Data Change" Event only fires when different value is written to terminal

Hey Jarrod,
You rock! Thanks for the workaround. Jaegen, I can't comment on if this will be fixed in the next release of LabVIEW. However, I can say that R&D is aware of it and looking into the problem.
 
 
Chris C
0 Kudos
Message 11 of 18
(2,501 Views)
Another quirk I noticed is:
If you drop an XControl in a VI, and write to the Value property, the "data change" event gets fired even if you write the same data.
If you pass a reference to the same XControl into a subVI, and in the subVI write to the Value property, the "data change" event gets fired only if you write different data.  Writing to the "Value (signaling)" property is necessary only in subVIs.
 
The only difference I notice in the property node, is that in the 2nd case, the reference is (strict).
 
S G
Certified LabVIEW Architect, Certified TestStand Architect, Certified Professional Instructor
0 Kudos
Message 12 of 18
(2,420 Views)

Hi all,

 

FYI writing to the 'Value Signalling' property doesn't always work depending on your data type.

 

I've been trying to pass in a Data Value Reference (DVR) to an Object as a XControl data change.

 

This failed because the DVR value is constant.  I tried writing to the 'Value Signalling' property but no joy.

 

Got round the problem by placing a DVR typedef in the Display State cluster.  Then added a new method to the XControl with a Connector parameter for a DVR.  New XControl methods call the 'Display State Change' Event in the XControl.  You can the access the DVR from the Display State In cluster, de-reference the DVR and then you have access to all the methods of the object - hurrah!

 

It would be really nice if you could make a XControl a member of the object, then it would have direct access to member variables via the object.ctl rather than accessor vi's.

 

Phill

0 Kudos
Message 13 of 18
(2,053 Views)

Hey Phill,

 

I'm not 100% clear on the details, because this thread is so old and I am unfamiliar with it, but it seems like you have the issue handled. I just wanted to let you know that we do have an idea exchange at ni.com/ideas, where you can post ideas for labview development and give feedback on ideas that others have posted. The board is regularly monitored by NI employees, and is a better forum for providing suggestions like yours to our development teams.

 

Thanks,

0 Kudos
Message 14 of 18
(2,041 Views)

Just stepped into this 'funny' bug a few days ago and into this very clever post after pinpointing the problem to the xcontrol.... ...needless to say (I suppose you might already know) that setting the value of an xcontrol in a vi by methoding on it, doesn't update the display if the control is not set to visible and or disabled=0. Thanks guys. 

0 Kudos
Message 15 of 18
(1,863 Views)

At this time I have decided to move out of the Xcontrol empasse, the application I am working on is already too much rich (in bugs perhaps) to include also these kind of problems.  Will get back on them maybe with something simpler some other time....

0 Kudos
Message 17 of 18
(1,849 Views)

10 years later and the part of the bug where writing to an XControl terminal that is not visible is still an issue. It seems completely reasonable to want to update a control before making it visible so it's always displaying fresh data.

0 Kudos
Message 18 of 18
(1,411 Views)