LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

write spreadsheet column limitation

Solved!
Go to solution

Hello, I'm trying to use write spreadsheet to save my structure of arrays.

I use an insert into array to join some arrays (10). I've got 450 variables (%.3f).

But when I read the saved file, it's showed me 30 Columns*15 lines columns instead of 450 columns *1 line.

In those arrays I've got SGL, INT and UINT variables.

My questions: 1) Is there any software limitation for that? Or I have made some mistake.

2)When I look at my saved file, the SGL variables should bring me, for instance, 3.145 or 127.236, but it brings me 3.000 or 127.000.

Please, is there anybody that can help me on that?

 

Regards

 

Felipe

0 Kudos
Message 1 of 11
(3,956 Views)

1) There is probably some theoretical limit, but 30 isn't it.  Are you seeing the effects of word-wrapping?  Either that or you are building the array incorrectly.

2) You need to take control of the data coercion.  Using Insert into Array, the first type in wins, and the rest are coerced to that type.  In your case, the array is either INT or UINT (look for thick blue wire) and the SGL numbers are being coerced to integer.  You should explicitly coerce the INTs and UINTs to SGL.  Look for To Single Precision Float in the numeric pallette. 

 

Without seeing your code to know exactly what you are doing, I am 99% sure that there is a better way than using Insert into Array.

0 Kudos
Message 2 of 11
(3,945 Views)
Darin, do you have any suggestion?
0 Kudos
Message 3 of 11
(3,926 Views)
Why don't you attach your code like Darin suggested? A Build Array probably makes more sense and yes, all of your data types need to be the same.
0 Kudos
Message 4 of 11
(3,922 Views)

I'll do that tomorrow...because I'm at home now. I'm going to send you only a section of my code.......it's very big.....

But anyway,,,thanks

 

Felipe

0 Kudos
Message 5 of 11
(3,917 Views)

My VI is something like that.....

thanks again

0 Kudos
Message 6 of 11
(3,915 Views)
Actually my VI is a lot of those structures
0 Kudos
Message 7 of 11
(3,914 Views)

what is the difference between those structures attached?

 

 

0 Kudos
Message 8 of 11
(3,913 Views)
Solution
Accepted by topic author Kitofelipe

Hi Kitofelipe,

 

the difference is easily to spot:

the build array results in a 2D array (it's not in "concat" mode), the insert array will give a 1D array. Just create indicators to see this (or move the wiring tool over the output connectors of both functions).

 

In your other eample you work with a 2D array in the shift register, so you will (nearly) always get a 2D spreadsheet file...

Message Edited by GerdW on 10-09-2009 12:02 AM
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 9 of 11
(3,911 Views)
What if the build array is in concat?
0 Kudos
Message 10 of 11
(3,906 Views)