Hey LV Forums!
I thought I'd share this little subVI I've made. At one point in time, I needed to copy all the attributes from one variant to another. Simple enough, really, but I figured someone might make use of it. Look, it even have error handling!
The problem:
Set Variant Attribute accepts a variant array of values for the attributes, but not an array of names.
The solution:
Get Variant Attribute returns, when "name" and "default value" is unwired, an array of variant names and an array of variants (attributes) associated with those names. So we just take those, throw them into a for loop with shift register, and write them one-by-one to the new variant.
The Code:
The Example: