473,394 Members | 1,811 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

DateTime.Ticks to DateTime

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.Tic ks / 10000)

Best Regards
Thanks

Jul 11 '07 #1
1 26207
fo****@googlemail.com wrote:
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.Tic ks / 10000)

Best Regards
Thanks
new DateTime(AnyTicks)

--
Göran Andersson
_____
http://www.guffa.com
Jul 11 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Michael Riggio | last post by:
Does anyone know a way to get system ticks in .Net? I found DateTime.Ticks, but that is equal to 100 nanoseconds. The reason I'm asking is because we're considering passing some sort of timestamp...
4
by: Jeroen CEuppens | last post by:
Hi, I want to measure a time (in ticks) between a couple of operations, with these code: long voor = DateTime.Now.TimeOfDay.Ticks; bmp1 = new Bitmap(@"\Network\im\ImageWeftIllum.bmp"); bmp2...
3
by: nriesch | last post by:
In the documentation, the "Second" property of class DateTime is a value between 0 and 59. In UTC time, approximately every year of so, a leap second is added at 00:00:00 UTC, so as to account...
2
by: Krzysztof Kazmierczak | last post by:
Hi All I wonder what is better to use: (DateTime) or DateTime.Parse Thanks Kind regards Krzysztof Kazmierczak
44
by: Frank Rizzo | last post by:
Any ideas?
21
by: Willie jan | last post by:
place this behind a button that fills a listbox. as you will see the time is now and then 0 or filled in???????????? by hitting the button. is there a way to determine the real elapsed time? ...
1
by: mp | last post by:
Is there a constructor for an mx.DateTime object which takes a datetime.datetime object? It seems like a pretty common thing to do but I didn't see such a constructor in the mx.DateTime docs. ...
4
by: Manikandan | last post by:
Hi, I'm inserting a datetime values into sql server 2000 from c# SQL server table details Table name:date_test columnname datatype No int date_t DateTime ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.