2004. január 17., szombat

How to hook into Windows' built-in screenshot function


Problem/Question/Abstract:

How to hook into Windows' built-in screenshot function

Answer:

{ ... }
if not fullScreen then
  Keybd_Event(VK_MENU, 0, 0, 0);
Keybd_Event(VK_SNAPSHOT, 0, 0, 0);
Keybd_Event(VK_SNAPSHOT, 0, KEYEVENTF_KEYUP, 0);
if not fullScreen then
  Keybd_Event(VK_MENU, 0, KEYEVENTF_KEYUP, 0);
{ ... }

The fullScreen value tells, if you wish to get a windowed printscreen or the full screen.

Nincsenek megjegyzések:

Megjegyzés küldése