Jump to content

Recommended Posts

This is not the first time I've seen this, but I think it's the first time I ever brought it up:

I am using UTC to a data table to date/time-stamp an hourly production output.  On my first sample, the UTC returned: 3724498800

I used this formula to convert it in Excel:  =(F24/86400)+DATE(1900,1,1)  where F24 contains the UTC value.

This produced a result, after formatting, of 1/8/18 3:00 PM

Which would be great - except today is 1/9/18 :)

Simple enough to correct for with DATE(1900,1,2), but the inaccuracy is concerning.  Am I doing something incorrectly?

Edit:  PS, I checked the Real Time Clock from Info Mode and it is correct.




Share this post

Link to post
Share on other sites

I tried reading UTC from PLC and got the same one day lag with that formula, but PLC has correct date data. Must be leap year missing a day every 400 years or something like that, there must be a code for conversion somewhere.

Why don't you put date into data table as integer or string? (I regretted it every time when I put it as a string)

Share this post

Link to post
Share on other sites

Edited:  incorrect info removed....me be tired and not thinkum clearly!

However, I use the RTC direct into my logging tables after some simple manipulation.  See below.  Might need another column (s?) in your table.  I do this method so no conversions are necessary to easily read the stored table.



10-Jan-18 21.58.gif

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this