Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

write spreadsheet file with indexing

I have an array of data received from my NI DAQ board, and would like to write the data to spreadsheet with the first column being the sample number (e.g., indexing). I have too much data to initialize and create an index array each time I want to save, nor do I want to load a special index spreadsheet to serve as the first column. What is the most efficient way to insert the sample number as the first column given an array of data, without using a while loop?

Example

Sample No. Data 1 Data 2 Data 3
1 # # #
2 # # #
3 # # #
.
.
.
0 Kudos
Message 1 of 2
(2,641 Views)
There is going to be a while loop somewhere although it may be in a VI funtion and you do not see it.

I recommend using Array to Spreadsheet String function found on the strings palette. Then you can insert array subset (of an array of strings but appear to be numbers counting up) into the first column then insert an array of strings of column headers into the first row of the data.

If you data can stay in LabVIEW, you might consider using a table or a multicolumn listbox.
0 Kudos
Message 2 of 2
(2,641 Views)