Converting Epoch time to datetime

  • Thread starter Thread starter Mister S
  • Start date Start date
M

Mister S

Guest
I have managed to convert from Unix time (time since 1970 in milliseconds) with the following:

Dim epochdate As DateTime
Dim seconds_since_epoch As Double
Dim converted_datetime As Date

epochdate = #01/01/1970 00:00:00#

seconds_since_epoch = 1531850023.185

converted_datetime = DateAdd("s", seconds_since_epoch, epochdate) '



However, the 'converted_datetime' is correct but doesnt include milliseconds. Is there a way to get milliseconds?

Continue reading...
 
Back
Top