How to implement a timer for regular events?

Posted by Torben Jonas on Stack Overflow See other posts from Stack Overflow or by Torben Jonas
Published on 2012-09-05T15:24:35Z Indexed on 2012/09/05 15:38 UTC
Read the original article Hit count: 193

Filed under:
|
|
|

I would like to implement some timers into my application. My goal is to provide an easy way to execute some function every x seconds/minutes so I thought about implementing a 1 sec, 5 sec and 15 seconds timer. The first thing i would like to update every 1 second is the built in clock (don't know if there is any other solution in c#, used this method in c++) Another use would be e.g. a sync function etc. which shall be executed every xx seconds.

My question is if there are any useful tutorials on this topic? It is the first time that I would like to implement such an timer system into one of my applications and I do not know if there are any things I have to keep in mind.

Thank you in advance for any answer :)

© Stack Overflow or respective owner

Related posts about c#

Related posts about wpf