12-21-2017 10:40 AM
Can I find coercion dots with VI scripting?
I have already used the VI Analyzer and know there is one coercion dot in this unfortunately large VI.
I have replaced a custom control cluster with a type-def control in order to get the benefit that if the type def changes, the changes will be exported everywhere the control is. I am concerned I have missed some instances. There is certainly a coercion dot on the diagram, but I don't know where. (It may be for another type.)
Solved! Go to Solution.
12-21-2017 11:16 AM
So if you select;
Block Diagram >>>Preformance>>>Coercion Dots
and set the "Single Wire" Maximum Number: to "0" and shut off the "Diagram" check mark...
Then run the VIA you should get a "Coercion Dots >>>Occurrence" in the Result List. Double clicking that occurrence should show the wire.
Ben
12-21-2017 11:44 AM
Ben's answer is the most useful... but I didn't actually know the answer and I was curious.
So, the answer is "Yes you can find coersion dots fairly easily with VI scripting". Something like this would do what you need.
12-21-2017 12:42 PM - edited 12-21-2017 12:43 PM
It's too late to edit my post, but I realized the above code won't quite work... it wouldn't find coersion dots on any code inside of a structure, loop, etc. You're going to want to use Traverse for GObjects with a class name of "Terminal".
12-22-2017 08:08 AM
I still kudo'd but you also should be closing the VI reference when you are done, otherwise you'll have a memory leak if done on a folder of VIs.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
16 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord