Showing results for 
Search instead for 
Did you mean: 

excel found unreadable data in spreadsheet/ exporting data to excel

My data comes out from the device over serial like this: 21.032, %,0000,0000 and then I run it in the vi through the converter to plot the first number on the graph ( see attached). I want to save this first number over the entire time of the program running in an excel file but when i open the test.xlsx file it errors and says that the data is unreadable. Have I not properly wired the write to spreadsheet funciton?



0 Kudos
Message 1 of 8

Your code works fine for me.

I saved it to a test.txt file on my hard drive.

Then I right-click on the file, and select for Microsoft Excel to open it.

The numbers show up in the first column.

0 Kudos
Message 2 of 8

So I cannot write directly to excel and can only save it as a txt file and then open that in excel? Is there a way to get the timestamp of acquisition that way too? I was hoping for more of an X,Y spreadsheet.

0 Kudos
Message 3 of 8

If you write your text with its comma-separated values to a file using the Write to Spreadsheet and name the file with a *.csv, you should generally be able to double-click on it and have it open in Excel. This isn't a true Excel file, but many people seem happy with it.



0 Kudos
Message 4 of 8

How do i create the csv file?

0 Kudos
Message 5 of 8

Write to Spreadsheet

0 Kudos
Message 6 of 8

What do I wire to the block then? I have the file path, but I have already created that text or excel file for it to work.

0 Kudos
Message 7 of 8

Just use a Build Array to add your timestamp. You can use whatever format you want for the timestamp.


Also, in order to read/write actual Excel files you need to use ActiveX. This has been asked MANY times before. You can program this yourself (an example ships with LabVIEW), or you can buy the Report Generation Toolkit.

0 Kudos
Message 8 of 8