02-14-2018 09:42 PM
Hi All,
How to get or set the value from container in test stand using index value (for loop method),
thanks in advance,
saran
02-15-2018 02:29 AM
To set the value to (from Container).
If you have a Container which has two fields Num1 and Num2 and you want to pass data from an array
Use:
Locals.MyContainer.SetValNumber("Num"+Str(Locals.Index+1),0, Locals.MyArray[Locals.Index]) (I have made the assumption that my types are numbers)
Now I have made my field names and types easy for me to do this.
You can use
Locals.PropName = Locals.MyContainer.GetNthSubPropertyName("", Locals.Index, 0)
Then use Locals.MyContainer.SetValNumber(Locals.PropName,0, Locals.MyArray[Locals.Index]). Again I am making the assumption that my types match.
hope this helps