NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

using unstructured TS data and labview variants

Hi Michael,

I see the same behavior you are getting.  I'm talking to R&D about it to see if it something they have seen before and if there is a workaround for it.
Kristen
National Instruments
0 Kudos
Message 11 of 12
(957 Views)
The reason this is not working is because you cannot assign variables of different types in expressions (your second step).  For example, if you had Locals.X that was a number, and Locals.Y that was a String, you couldn't convert the type of X to Y by assignment.  I would expect this step to generate an error since you are doing something that cannot really be done.  We will have to look at that problem to determine why that is happening.

However, if you want to make a copy of an object, you can always clone it.  I replaced your second step's statement with the following:
ThisContext.Locals.SetPropertyObject("variant2", 0, Locals.variant.Clone("", 0)) and now it works.

Allen P.
NI
0 Kudos
Message 12 of 12
(949 Views)