Converting hours to ticks

  • Thread starter Thread starter maflatoun
  • Start date Start date
M

maflatoun

Hi guys,

How do I convert hours to ticks? Let's say I have 1000 hours and I want
to convert it into ticks? Is a tick 1 second?

Thanks
Maz
 
How do I convert hours to ticks?
Let's say I have 1000 hours and I want
to convert it into ticks? Is a tick 1 second?

TimeSpan.TicksPerHour

Till
 
Hi guys,

How do I convert hours to ticks? Let's say I have 1000 hours and I want
to convert it into ticks? Is a tick 1 second?

You can use the TimeSpan class:

TimeSpan t = TimeSpan.FromHours(1000);

t.Ticks;

One tick is 100ns (see help).

hth,
Max
 

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