%02d/%02d/%04d %02d:%02d:%3.1f
Put the parts together with a DATE/TIME to SECONDS function if you need to.
Blog for (mostly LabVIEW) programmers: Tips And Tricks
You're only getting a 2 because you're using read from spreadsheet file and returning doubles. When the timestamp string gets converted to a double, it sees "02/..." It doesn't know how to convert a slash into a double so it assumes the number ends there.
I suggest you wire a %s to Read from Spreadsheet File. This will give you all the data in strings. Now you can take out the first column and convert it to timestamps (using Scan from String), then take out all the actual data and convert it to doubles.
Message Edited by Marc A on 03-01-2007 11:20 AM
Of course, that won't work either if you put in a string that starts out "Log File"
You probably should read the file with "%s" format, and get an array of strings.
Throw away the first line of commentary stuff.
Strip out the first column.
For every row in the first column, run the string through the SCAN FROM STRING function, and maybe the DATE/TIME to SECONDS function to get a timestamp value.
Then run the rest thru a STRING TO NUMBER conversion (no loops needed) to get your data.
HTH
Blog for (mostly LabVIEW) programmers: Tips And Tricks
OK, I know why. In version 8.2, Read from Spreadsheet File is a polymorphic VI that has different data types. 8.0 doesn't have this capability. To get around it, use Read Text From File.vi, then wire the string ouput to Spreadsheet String to Array.vi. Wire a 2D string array to the array type input and you'll get a string array out.
Edit: like this...
Message Edited by Marc A on 03-01-2007 01:51 PM