LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I automatically create a new file at the beginning of a new day, otherwise I only want to append that days file?

In my robotics application I store my data using "Write to Spreadsheet.vi". I would like to append the file each time I run the program on any given day. On a NEW day I would automatically like to create a new file with a smiliar name and append that file for the day on which it is created. It's easy to do using the "Write to Measurement File. vi" but the text file created is vertical rather than horizontal, so I would like to use "Write to Spreadsheet". Any suggestions?

 

Also how to I include my VI as part of this question for others to see?

 

Thank you.

0 Kudos
Message 1 of 2
(2,693 Views)
Does the file you are writing have a timestamp in it?  If so you could read the timestamp from the last time it was written and see if the day has changed, handling the name of the file appropriately.  The easiest way to record the timestamp is probably to write the timestamp as the number of seconds that have elapsed since 12:00 am on Firday January 1st 1904 in UT.  The "Get Date/Time in Seconds" function will give you this value.
Message Edited by jmcbee on 03-05-2009 12:56 PM
0 Kudos
Message 2 of 2
(2,684 Views)