LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

for loop array index not from 0

HI!
I have an array that is wired into a For Loop. Inside the For Loop there is already a single Array content available as there is this autoindexing feature (?). I do want to change the Array from a certain position different from 0 onwards to the end e.g. change positions 4, 5 and 6 in a for loop executing 3 times. But the for loop and the autoindexing feature start at 0. Can I change this in an elegant way. At the moment I'm running thru the hole array and begin changing at a certain position.
0 Kudos
Message 1 of 3
(2,657 Views)
Yes, disable autoindexing on the tunnel and use "index array" inside the loop. Use [n]+4 as index and wire a "3" to the loop count in your particular example.

If you want to keep the entire array and just replace a few elements with updated values, the array needs to be fed in via a shift register. Write the new elements at the desired position using "replace array subset" (see attached very simple example).
0 Kudos
Message 2 of 3
(2,657 Views)
Thanks. That's all I wanted
Best Regards
Andreas
0 Kudos
Message 3 of 3
(2,657 Views)