09-24-2019 09:39 AM
Can someone explain why this isn't working for me. I want the same thing. I want to change my ini file into a cluster with variable names the same the keys. I created a header cluster that has the same names but ideally it would be dynamic. Why is my type cast have broken wire. The message is "polymorphic terminal cannot accept this data type."
09-24-2019 01:06 PM - edited 09-24-2019 01:08 PM
@SoftWEng wrote:
Can someone explain why this isn't working for me. I
No. You gave us a picture of your VI. We have no idea what is going on with that Header cluster constant.
If you attached a real live .vi, then yes we can probably explain it.
On second thought, Yes, I think I can explain it.
My guess? Your cluster constant is pink, which means it probably has some variable length elements in it. No way to clearly typecast an array. Actually, the array itself is an array of strings which means it has variable length array elements in it.
09-24-2019 01:20 PM
Thanks for the tip. The header control is a lot of string constants with labeled names. The array coming out is an array of strings. I just tried a little test and realized the type cast can take an array of numbers in but breaks when I try to put an array of strings in no matter what type def I put in the top. I guess I will have to use bundle by name and expand the array.
09-24-2019 01:49 PM
This llb allows to write named cluster into ini file and read it back. Output is variant, you need to convert variant to data.
A newer version might be available from VIPM, may be in OpenG libraries (http://sine.ni.com/nips/cds/view/p/lang/en/nid/209027).