- Specifies the Handle to the Window to be captured otherwise NULL to capture the Desktop.
capture the entire window
capture only the client area of the window
The first parameter, HWnd, should either be the Handle of the window to capture, or NULL to capture the desktop.
The Desktop window is all client area so the 2nd parameter can be ignored. This parameter is only effective with a standard window that has a menu area for instance, in that case capturing the client area will not include the menus, etc.
|Capture (Visual Basic)||Copy Code|
' Capture the Desktop ImageControl1.Capture NULL, 0 ' Capture only the client area of the Form1 Window ImageControl1.Capture Form1.hWnd, 1