Editing contents of a labview array

sgccarey picture sgccarey · Mar 14, 2013 · Viewed 9.3k times · Source

I'm trying to increment specific elements by 1, in order to log results as they come in. I'm trying to read an element, add 1 to it, and then write it back to the same memory address. Why isn't this simple?

In code it would be something as simple as;

array1[element1] = (array1[element1]+1)

or

array1[element1]++

Arrays seem to be either read (indicators) or write (controls)? This is really frustrating, and there's very little help online.

Answer

user2169263 picture user2169263 · Mar 14, 2013

You can use an "Array index/replace" element inside a "In place element structure":

usage of in place element structure