LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

writing spreadsheets to a directory

I want to write spreadsheet files each to a single directory. Each is a set of data from my program which executes several loops. For each loop a 2D array is outputted and this is written into a spreadsheet file. I use the write to spreadsheet file function, but this requires a file name, which is fine for single files. But what should I do for the case of multiple files. I have experimented with changing the file name input for each loop interation by using string functions, but have not had much luck.
0 Kudos
Message 1 of 4
(2,674 Views)

I have experimented with changing the file name input for each loop interation by using string functions, but have not had much luck.

How did you go about this?
if you could eloberate, probably we could suggest a method to achieve this.
Message 2 of 4
(2,672 Views)
Thank you for your reply,

I have attached my vi here. I have created a while loop which adds the loop iteration number to the end of the filename. It seems to me that what I have to do is create a dummy excel file to begin with, and then browse to that excel file. Then the labview program will browse to that same file when it runs. Subsequently I wish to add the loop iteration number to the end of the file name. The problem seems to be that the file name ends with .xls and it keeps adding .xls1, .xls2, .xls3, instead of 1.xls, 2.xls, 3.xls, which is what I want. I am welcome to any suggestions you may have.
0 Kudos
Message 3 of 4
(2,655 Views)
Try what's in the attached image.  Be sure to wire a 0 to the "Length" terminal, otherwise it will overwrite characters instead of just inserting them.

Good luck!




Message Edited by Will.D on 10-16-2006 01:23 PM

Message 4 of 4
(2,647 Views)