LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why I can't initialise the string variable eventhough, I set the reinitialise all to default thru menu or i initialise it before the dataflow begins?

Here is my vi. When I do either of two settings, the string would'nt be flushed emypty, instead the D(n) are added up! I am puzzled. I did same thing before and it works fine. I can't figure it out.
0 Kudos
Message 1 of 2
(2,438 Views)
The SR in the inner for loop is not initialized so it keeps its data from one run to the next. I see three solutions:

1. You can remove this for loop and put the SR on the outer for loop, initializing it to empty.

2. Keep the inner for loop but when the outer loop executes the first time (i==0) don't concatenate the content of the SR.

3. Remove the inner loop and ouptut the string coming out of the case structure to an auto indexing tunnel. Input the outcoming array of strings to Concatenate Strings before formatting.


LabVIEW, C'est LabVIEW

Message 2 of 2
(2,438 Views)