LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I have data from a 2D array look the same way on the table?

I appologize for not attaching my code, It's extremely large.  So I thought it would be best to focus on what I need help with. 

I captured a screenshot of the part of my code I need help with.

cap3.PNG

 I tried to to turn "stick 1D array" into 2D array. Note: This code is in the state machine. 

Below is the result I am getting. I just want the numbers on the table to look the numbers in the array. I know a long way to do it, but does anyone know a short cut by any chance? I tried to change precision from "number to fractional string" block, it didn't work for me. Any suggestions? 

cap1.PNG

0 Kudos
Message 1 of 4
(720 Views)

You can use "format into string", but you need to wrap two autoindexing for loop around it.

(Right-click your array elements and see what their format is, then use that.)

Message 2 of 4
(691 Views)

You could feed the double array to 'Array To Spreadsheet String' followed by 'Spreadsheet String To Array' with a 2D string constant as array type input. 'Format string' could be %0.7f.

Message 3 of 4
(642 Views)

@UliB wrote:

 'Format string' could be %0.7f.


or %#.7f 

alexderjuengere_0-1651493625545.png

Spoiler
trailing-zeros.png

 

 

Message 4 of 4
(633 Views)