How Does One Convert A .net Tick To A Python Datetime?
I have a file with dates and times listed as huge numbers like 634213557000000000. I believe this is a .NET tick. That's the number of 100 nanosecond increments since midnight on J
Solution 1:
datetime.datetime(1, 1, 1) + datetime.timedelta(microseconds = ticks//10)
For your example, this returns
datetime.datetime(2010, 9, 29, 11, 15)
Post a Comment for "How Does One Convert A .net Tick To A Python Datetime?"