How to get Windows desktop image

I’m writing an application to control a PC remotely and I need to grab the image of the remote PC’s desktop to send to my client. Does anybody know the name of the Windows function (Windows 2k or Windows 98)to get the desktop image? My application is written in VC++.

thanks

You can use GetDesktopWindow() to get the HWND of the desktop, then GetDC to get its device context… From there you could do something like send a bitmap of the desktop. There may be a faster way though.

Owlet