LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Idea on a best way to combine an array in my case

Solved!
Go to solution

Hello everyone,

 

I am working on a output module for outcomes.

 

I would like to have my output in an Excel file as below:

 

Name 1:  Value 1

Name 2:  Value 2

Name 3:  Value 3

 

 

The values are fetched by some computations while names are defined by myself.

 

For the values, I am going to put them in an array, which would become output like this:

 

Value 1

Value 2
Value 3

 

Then I use transpose array to make it as   subarray 1 (Value1 Value2  Value3)

 

I could define an array  as

 

name 1

 name 2

 name 3 

 

and transpose it to subarray 2 (name1 name2 name3)

 

Then I use 'Build array' to combine them and become:

 

  name1 name2 name3

  value1  value2  value3 

 

Finally transpose it to:

 

 name1  value1

 name2  value2

 name3  value3

 

 

Feel like a lot of redundancies but anyway it will work, does anyone have a better idea for that?

 

 

Any idea is well appreciated,

 

Thanks,

+Kunsheng Chen

 

 

 

 

 

 

Message Edited by Kunsheng Chen on 03-11-2009 10:05 AM
0 Kudos
Message 1 of 3
(2,319 Views)
Solution
Accepted by topic author Kunsheng Chen

How about something like this :

Edit : I just looked at the output of the 'Build Array', you will need one transpose array if you want :
name : value
name : value
etc
Message Edited by Cory K on 03-11-2009 10:20 AM
Cory K
Message 2 of 3
(2,312 Views)

Thanks. I just realize I don't have to tranpose

 

name1

name2

name3 

 

into 

'name1 name2 name3' before using 'Build Array'.

 

 

Thanks a lot!

 

+Kunsheng

0 Kudos
Message 3 of 3
(2,295 Views)