LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Graph Spreadsheet

This should be a simple question, but I just can't figure out how to fix it. I am almost finished with this program, (yay!) but have one small issue. The graphs that I write to a spreadsheet append properly, bu they do it at the bottom of the same column rather than in another column. Is there a way I can get it to go in a new column every time? Because I will be taking several graphs, most of them at least 500 data points long, so this column could get very confusing, very quickly without being able to tab over.

I have attached the section of the program pertaining to the spreadsheet.
----------------------------------------------------------------------------------------------------------------------------------------------------
I've got a sneaking suspicion that Jesus might have been made of bread. Why else did they have to put him in a warm cave and wait three days for him to rise?

Damnant quadnon intelligunt - They condemn what they do not understand.
0 Kudos
Message 1 of 8
(2,699 Views)
Hi JohnGalt,

Try only writing to file once by concatenating your waveforms. The problem is once that file is written to disk you will have line feeds at the end of each row. So if you need to append new columns to the existing file you are going to need to get rid of those nasty little line feeds to do it. This can be done but from what I saw of your program is not necessary. Just try writing all the data once.

hope this helps

cheers,

--Russ
0 Kudos
Message 2 of 8
(2,690 Views)
That sounds reasonable, but it brings up another issue. How do I cocatenate them? It doesn't work with cocatenate strings. Is it just some other function I haven't found yet?
----------------------------------------------------------------------------------------------------------------------------------------------------
I've got a sneaking suspicion that Jesus might have been made of bread. Why else did they have to put him in a warm cave and wait three days for him to rise?

Damnant quadnon intelligunt - They condemn what they do not understand.
0 Kudos
Message 3 of 8
(2,687 Views)
Try using "build array".  You should be able to a) concatenate the waveforms or b) create a 1D array, depending on how you use it.
0 Kudos
Message 4 of 8
(2,684 Views)
Well, that does make it simpler, which is good. However, it does not solve the problem of making it read in a seperate column. Any other ideas? Could a Tab Constant be added anywhere to make it work?
----------------------------------------------------------------------------------------------------------------------------------------------------
I've got a sneaking suspicion that Jesus might have been made of bread. Why else did they have to put him in a warm cave and wait three days for him to rise?

Damnant quadnon intelligunt - They condemn what they do not understand.
0 Kudos
Message 5 of 8
(2,664 Views)
Sorry, wouldn't let me edit last post, but the question is this. When the Multiple Time Columns feature is off, it writes, just all in the same vertical column. However, when I activate the Multiple Time Columns, the Excel file ends up blank. What could be the problem with this? Is it not supposed to be used for an array of waveforms?
----------------------------------------------------------------------------------------------------------------------------------------------------
I've got a sneaking suspicion that Jesus might have been made of bread. Why else did they have to put him in a warm cave and wait three days for him to rise?

Damnant quadnon intelligunt - They condemn what they do not understand.
0 Kudos
Message 6 of 8
(2,653 Views)
The only way to get Export Waveforms to Spreadsheet File to write data in multiple columns is to pass it a 1D array of waveforms like in the attachment. If you put all of your acquisition in a loop and build an array of waveforms, then when the acauitisiton is complete you do a single write and when written, you will get each waveform in it's own column. You can have multiple time columns as well. This is what I did in the example. If at any point, you write a single waveform and want to add a new column, you will first have to read in the existing file, append the new waveform, and then write the new array of waveforms back out. You will need to replace the existing file when you do this.
0 Kudos
Message 7 of 8
(2,651 Views)
OK. I managed to figure out how to fix it. The reason it wasn't writing seemed to be related to the file. So what i did was throw in a create or replace file function, and that seems to get it writing what I want. It now comes out with both channels in the same column, delimited by a comma between them. I think it works well enough for my purposes. Thank you very much for your help.

JohnGalt
----------------------------------------------------------------------------------------------------------------------------------------------------
I've got a sneaking suspicion that Jesus might have been made of bread. Why else did they have to put him in a warm cave and wait three days for him to rise?

Damnant quadnon intelligunt - They condemn what they do not understand.
0 Kudos
Message 8 of 8
(2,635 Views)