Z
Zach
I seem to remember that there is a method
for establishing time elapsed since midnight,
which is it?
Thank you.
Zach.
for establishing time elapsed since midnight,
which is it?
Thank you.
Zach.
Morten Wennevik said:Hi Zach,
DateTime d = DateTime.Now;
MessageBox.Show(d.Hour + " " + d.Minute + " " + d.Second);
Zach said:I seem to remember that there is a method
for establishing time elapsed since midnight,
which is it?
Thank you.
Zach.
Hans Kesting said:TimeSpan sinceMidnight = DateTime.Now - DateTime.Today;
double secs = sinceMidnight.TotalSeconds;
Jon Skeet said:or just
double secs = DateTime.Now.TimeOfDay.TotalSeconds;
Thank you Hans,Hans Kesting said:TimeSpan sinceMidnight = DateTime.Now - DateTime.Today;
double secs = sinceMidnight.TotalSeconds;
Hans Kesting