From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I display all values of an array on each row of a table

Hello all,

 

I am building a sub vi  in which I am getting an array values of ''voltage" and "current" from the main vi. All these values I want to display in a table. If it is a numeric value I can easily use "format into string" vi but as it is an array I used "array to spread sheet string". Now the problem is after each iteration i get a lot of values of voltage and current. These values I want to display in a single row(without losing any value),rather than multiple values in a single row of each column of voltage and current. I have already use build an array express vi, it makes my work easier,but I cant customize it in the future. Attached is the main and sub vi.

 

Looking for a solution!! 

0 Kudos
Message 1 of 8
(2,054 Views)

Hi crusader,

 

can you provide an example of the output format you need?

 


crusader@@1 wrote:

These values I want to display in a single row(without losing any value),rather than multiple values in a single row of each column of voltage and current.


I just changed your subVI like this:

 

Btw. don't call them "matrix", those are plain 2D arrays! "Matrix" is a special datatype in LabVIEW used for algebra…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 8
(2,038 Views)

Thanks for your prompt reply. Attached is the example!

0 Kudos
Message 3 of 8
(2,023 Views)

Hi crusader,

 

what should I recognize on this small blurry downscaled image?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 8
(2,011 Views)

Sorry my mistake!

 

Please find the edited one.

Edited_Example.png

0 Kudos
Message 5 of 8
(1,995 Views)

Hi crusader,

 

start like this:

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 6 of 8
(1,990 Views)

Hi Gerd!

 

thanks for the reply! the data output is 3 dimensional array where as table is 2 dimensional array, so actually i want to display it in table control, second i want to display date and time in separate column and in the first column the serial number i.e :1,2,3,4,5...

 

Thanks!

0 Kudos
Message 7 of 8
(1,973 Views)

Hi crusader,

 


crusader@@1 wrote:

the data output is 3 dimensional array where as table is 2 dimensional array, so actually i want to display it in table control


In my example image the "data output" is a 2D array of strings as shown in the frontpanel!

 


crusader@@1 wrote:

i want to display date and time in separate column and in the first column the serial number i.e :1,2,3,4,5...


I asked for an example of what it should look like, but in your example image Timestamp was shown in the first column and no serial number!

 

When you need time and date as separate columns then you need to add those data as separate columns - you can do so similar as is shown in my last image.

The same applies for that serial number: add it as additional column the same way as I prepended the DateTime column…

 

I have shown you how to create the desired 2D array of strings, you just need to add more columns!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 8 of 8
(1,966 Views)