02-24-2019 05:52 PM
The terminal solution only works if the control has a terminal, which the control on the panel of a .ctl will not. Try using the Value property instead of the Terminal.Data Type property.
02-27-2019 12:07 AM
Yes, Darren, reading Value property does not return any error. However, I cannot find how to use obtained value Variant.
02-27-2019 10:35 AM
@_Y_ wrote:
However, I cannot find how to use obtained value Variant.
I don't understand your question.
02-27-2019 01:15 PM
I can read Value but cannot use it for obtaining any information about terminals.
This is illustration of my attempts; both branches launch errors in last steps:
02-27-2019 01:20 PM
Look at my previous screenshot...you can get an array of the terminal data types from the Get VI Information VI.
02-27-2019 01:32 PM - edited 02-27-2019 01:32 PM
Sorry, I tested it first and forgot to present in the message. It returns number of terminals but not their types:
02-27-2019 01:50 PM
Seems I have solved the problem just now. But my hack is really ugly.
The script creates dummy VI, adds a Call By Reference node in its BD, connects the node to the type-defined input, and reads terminals of the Call By Reference node:
It works... but I'm not happy with such ugly things. Probably there is a better way.
02-27-2019 01:52 PM
The VI you're using in the For Loop should be Get Type Information.vi, not Get VI Information.vi. When you use the proper VI in the For Loop, you'll get the type info you're looking for.
02-27-2019 02:27 PM
Yes, Darren, this was my mistake. Sorry. I placed wrong VI in BD and considered solution as non-functional.