tags:

views:

53

answers:

1
+2  A: 

All the CaptureScreen function does is create a compatible bitmap the same size as the screen and then write it out to disk, so you're seeing the default contents of the bitmap (black). To capture the screen you need to create a compatible DC, select the bitmap you made into it and blit from one DC to the other. Then you need to unselect your target bitmap before you start writing the file.

Stewart
I'm very new to the windows api. To select the bitmap into the DC, I i know I should use SelectObject(). I am already creating the compatibleDC with screen=GetDC(0); memDC = CreateCompatibleDC(screen); is this the correct way to do this? How do I blit into this?
Wade Tandy