http://winprog.org/tutorial/

Try searching, I bet this question has been asked a lot in the Windows Programming forum.

Brendan