07-22-2015 01:39 PM
How to iterate through a 2d array in such a manner, if the array contents is:
Header1 Header2 Header1 Header2 Header1 Header2.......(repeat sequence)
4 False 2 True......................(repeat sequence)
7 False 3 True.....................(repeat sequence)
3 True 2 false ...................(repeate sequence)
5 False 6 false....................(repeat sequence)
But, it should iterate:header 1 row 1, then header 2 row 1, then header 1 row 2, then header 2 row 2......
Once it finishes iterating through columns 1 and 2, it should move on to column 3 and 4 and do the same process.
07-22-2015 01:49 PM - edited 07-22-2015 01:49 PM
What version of LabVIEW are you using? If you have the concatinating tunnels (new in LabVIEW 2013?), then this is simple.
07-22-2015 07:17 PM - edited 07-22-2015 07:19 PM
That is Great!! and I have labVIEW 2014 so this works out.
Thank you!
Also, just curious not related to my original post (Well, it might be), how do most people really understand and learn to operate labVIEW at a high level?
07-22-2015 08:21 PM
One way is to find a LabVIEW Guru and apprentice yourself to him/her. You want to see "good code" and have an explanation of "what makes this good". There are some General Principles that seem to characterize good code -- one is that almost every VI fits on a single screen (which means that there are probably a lot of sub-VIs). Early in my experience with LabVIEW I read "The LabVIEW Style Book", and learned a lot from it.
Bob Schor
07-23-2015 03:50 PM
So, another question....
How do I make it so it stores (Using crossrulz array content) ab, cd, ef in the first two columns.
Then it stores gh, ij, kl in the next two columns, and repeat.....
07-23-2015 03:54 PM
@quexin wrote:
How do I make it so it stores (Using crossrulz array content) ab, cd, ef in the first two columns.
Then it stores gh, ij, kl in the next two columns, and repeat.....
Please re-phrase your question it isn't clear what you are asking. You say put "ab, cd, ef" in the first two columns, but you just listed three things if the commas is the delimeter between items. How would you want to store three things in two columns? Please post clearly what you want your output to be, and post any code you have tried if you have any.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
07-23-2015 04:24 PM - edited 07-23-2015 04:27 PM
so the array will look like this in the end:
Column1 Column2 Column3 Column4 Column5 Column6..............
a b g h m n
c d i j o p
e f k l q r
I have attached some code....it is really messy because I am trying to understand what is going on in for loops and coming out of array operations, therefore, I created some indicators. I did not add much after using Crossulz code.
07-23-2015 04:30 PM
@quexin wrote:
Column1 Column2 Column3 Column4 Column5 Column6..............
a b g h m n
c d i j o p
e f k l q r
Uh....isn't that the input? Are you asking how to reverse crossrulz code?
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
07-23-2015 04:30 PM
If what you want is to revert the operation, you can use the same (basically) operation that crossrulz gave, but looking transpositionly.
07-23-2015 04:32 PM
.........whoops my bad....I have no idea what I am trying to accomplish....Sorry for wasting time on that post