LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

write to spreadsheet file

I am trying to write the data recorded from 6 different channels into a spreadsheet using the "write to spreadsheet function". I want each channel appearing in a different column so I guess I have to set the value of transpose as true, first of all I don't know how to change that setting (I'm a begginer) and when I was trying to figure out how to do that I guess that I damaged the write to spreadsheet.vi file by mistake and the indicator for to transpose is not showing anymore. It is also possible to put titles to the columns? Thanks
0 Kudos
Message 1 of 5
(3,181 Views)
The "Write to Spreadsheet File" function has a transpose? input:


If you believe you "damaged" the "Write to Spreadsheet File" function you should do a repair on your LabVIEW installation so that it gets replaced with the original copy.

To get titles you will need to put them in yourself before writing out the data. You can do this by using the "Write Text File" function and simply write out your header. Then call the "Write to Spreadsheet File" VI with the "append to file?" input set to true.

An alternative approach would be to use the "Write to Measurement File" Express VI. This uses the name of the signal as the "title".

Message Edited by smercurio_fc on 09-12-2007 01:02 PM

0 Kudos
Message 2 of 5
(3,166 Views)
I solved my problem with the write to spreadsheet.vi file, the terminal for transposing wasn't connected. I tried your suggestion of using the "Write to Spreadsheet File" VI and it append to the file with the data in the top of the list but the headers appear in the same colum. How can you separate the different headers to put each one in a column? I'm using labview V. 5.0
0 Kudos
Message 3 of 5
(3,143 Views)

You don't need to transpose, here's what I do and I use LabView 7

Say you have 4 parameters you have values for (Vin, Current, Temperature, Frequency)

The 3 main functions I use are, Write to File, Format into String, Concatenate Strings

Your 4 parameters will be the inputs to Format Into String, the output "Resulting String" will go to first node of the Concatenate String. To the second node, connect this thing called "end of line constant".  The output of this concatenate string called the "Concatenated String" is now the input to your Write to File block, "data" node.

Save this file in .txt format, then right click and open your file with Excel

You should see your data in the following format, in columns A, B, C, D of your excel sheet (values are of course made up)

Vin     Current     Temperature     Freqency

1           1.1                 25                    10

1.2         1.0                26                     11

Now you are free to manipulate and organize your data in Excel as you wish. Hope this helps.

 

0 Kudos
Message 4 of 5
(3,117 Views)
That works fine for me, thank you
0 Kudos
Message 5 of 5
(3,101 Views)