08-07-2014 01:32 PM
Hi everyone, is there a function in Test Stand to return a portion of a "NUMERIC" array starting at a specific index within the array? I see functions for "STRINGS" but nothing for "NUMERICS."
Thanks so much!
Solved! Go to Solution.
08-07-2014 01:54 PM
You can use an expression such as the following:
Locals.MyArray[3..5]
This will give you an array comprised of elements 3 through 5 from Locals.MyArray. This should work for all array tpes in TestStand.
Hope it helps!
03-02-2018 12:46 PM
Daniel,
I found your response very helpful (Thank you), and I extended it slightly to allow a more dynamic selection of my array subset. I had to use the Evaluate() function to make this subset a little more variable, as I've demonstrated below:
This example returns all array elements starting at Locals.offsetIndex through the end of my array.
Evaluate("Locals.MyArray[" + Str(Locals.offsetIndex) + ".." + Str(Locals.MyArray.GetNumElements() - 1) + "]")
Thanks for sending me down the right path.
Ken M.