LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

time stamp difference wrong. why??

Solved!
Go to solution

You have a misconception about what that function is supposed to do. It takes the double on the input, interpreting it as number of seconds since January 1, 1904 GMT and turns it into a timestamp representing the same absolute time. In that sense it is fully timezone independent as both input and output are interpreted in respect to GMT.

And now you pass it to a timestamp control which by default is configured to display local time, so the time in seconds since January 1, 1904 GMT is adjusted with the timezone offset, but this happens in the timestamp control which is configured to display local time.

The quick but wrong approach would be to configure the timestamp control to display in UTC, as UTC is fundamentally equivalent to GMT (don't say that to a data/time specialist as he will wildly disagree with that, but for the purpose of the computer implementation it is equivalent enough). 

The right approach is to treat the relative time as relative time instead of trying to convert it to an absolute time, and simply use a normal double indicator configured to display relative time format!

Rolf Kalbermatter
My Blog
0 Kudos
Message 11 of 11
(566 Views)