1

I have a script that creates data and stores the with a name that contains the output of DateTime.Now.Ticks.ToString("x"); I now need to convert this value back to a human readable time in order to figure out when the data was generated for a report but I cant find any tools or equations to do this anywhere. All help appreciated.

some values i'm trying to convert:

8d84e63114d60d2
8d84e6645daa831
8d84e67c9ba1367
8d84e6993166d49
Jack Burke
  • 81
  • 6
  • 3
    `new DateTime(long.Parse("8d84e6993166d49", NumberStyles.AllowHexSpecifier))`. – Jeroen Mostert Sep 01 '20 at 11:42
  • 1
    `X` is hexadecimal. So you have two steps to your problem - convert hex back to the same type that `Ticks` is. Then call the appropriate constructor - https://stackoverflow.com/a/1489270/34092 . – mjwills Sep 01 '20 at 11:42
  • Thanks @JeroenMostert a small conversion script seems to be exactly what I needed – Jack Burke Sep 02 '20 at 13:10

0 Answers0