04-19-2013 08:03 AM
Hello,
I have imported an excel to an array and im trying to use a timed loop to run the values of the array on a timed interval. One of my problems is that the array is 2D and i cant use its length to stop the loop. I want to use witch value of the array in the loop in each iteration of the loop and i want the loop o stop when the counter equals the length of the array. Can someone help me plz here is the labview.
04-19-2013 09:47 AM
It is really unclear what your question is. Could you clarify?
If you are struggling with why you have a broken wire it is because you are sending an array to the stop of the loop. When you use the array size function on a 2D array it returns a 1D array with the size of each dimension. When you then use the greater than function it returns a 1D array of Booleans. It compares each element of the array size to the current count of the iteration terminal.
To use this to stop your loop you need to reduce it to a single element some way before you send it to the stop control of the loop. You could apply an "and" or "or" function to the out put of the greater than or pull out a single index out of the single greater than array.
In the image logical AND, logical OR, or element could be used to stop the loop. You just need to choose one that gives you the behavior you need.
04-19-2013 10:11 AM
Thank you very much. It worked perfectly. Now im able to configure the excel table how i want and the loop stops perfectly.
04-19-2013 10:28 AM
No problem. Gald it worked for you.