LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Write elapsed time to a spreadsheet in hours:minutes:seconds format

Hi everyone,
 
I've been trying to write an elapsed time to a spreadsheet file in an hours:minutes:seconds format, but the time is displayed in a floating point value of seconds..
how can I write to a spreadsheet in an hours:minutes:seconds format.
 
Thank you,
 
James-
0 Kudos
Message 1 of 3
(9,296 Views)
You can convert a timestamp to a string with the Format Date/Time String and if you convert the rest of your data to a string, you can use the Write to Spreadsheet File. In newer versions of LabVIEW you can select the type of input data to be strings. What version are you using? If you have an older version, you can modify Write to Spreadsheet File by following the directions on the block diagram. Make the changes and save it with a new name and to a new location. You could also just use the Array to Spreadsheet String and a Write File.
Message 2 of 3
(9,285 Views)
I often use a subVI that converts Seconds to Hours, Minutes and Seconds. Use the Quotient and Remainder function to divide your elapsed time by 3600, 60 and 1. You can then convert those values to a modified string and use the Write to Spreadsheet File.

As Dennis said, newer versions of LabVIEW's Write to Spreadsheet File.VI can handle arrays of Double, Integer or String automatically, and in older versions, the Write to Spreadsheet File.VI can be modified and copied to handle strings.

Hope this helps.

-)

(Written in 8.5)



Message Edited by LabViewGuruWannabe on 01-18-2008 09:28 PM
Download All
0 Kudos
Message 3 of 3
(9,281 Views)