DateTime.Ticks to DateTime

  • Thread starter Thread starter fososs
  • Start date Start date
F

fososs

Hi all,

Do you know any other way how to convert DateTime.Ticks (in Int64) to
DateTime? I m using this way...


Int64 AnyTicks = 633195783803593750; //for example

DateTime.MinValue.AddMilliseconds(AnyTicks/10000)

you can prove it by typing of this....

DateTime.MinValue.AddMilliseconds(DateTime.Now.Ticks / 10000)

Best Regards
Thanks
 
Hi all,

Do you know any other way how to convert DateTime.Ticks (in Int64) to
DateTime? I m using this way...


Int64 AnyTicks = 633195783803593750; //for example

DateTime.MinValue.AddMilliseconds(AnyTicks/10000)

you can prove it by typing of this....

DateTime.MinValue.AddMilliseconds(DateTime.Now.Ticks / 10000)

Best Regards
Thanks

new DateTime(AnyTicks)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top