Chapter 24. TIMERS

It is often necessary to schedule a periodic event to execute some program code. A word processor can use such an event to trigger file saves; a programming environment, to detect prolonged idle time that can be used for heap garbage collection; and a screen saver to perform animation on the display. The Win32 API provides timers to achieve this type of operation. Timers are registered events that fire at programmed intervals.

Timers are allocated from a common pool for all processes of the system. Although previous versions of Windows were limited to just a few timers, Windows NT/2000 and Windows 9x do not have this constraint. In Windows 9x, more than 2,500 system timers can be created. Under NT/2000, it is possible to create ...

Get Microsoft Windows 2000 API SuperBible now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.