Perhaps this link will help:
http://wiki.lazarus.freepascal.org/D..._with_Graphics
Specifically this info:
Taking a screenshot of the screen
Since Lazarus 0.9.16 you can use LCL to take screenshots of the screen on a cross-platform way. The following example code does it (works on gtk2 and win32, but not gtk1 currently):
Code:
uses LCLIntf, LCLType;
...
var
MyBitmap: TBitmap;
ScreenDC: HDC;
begin
MyBitmap := TBitmap.Create;
ScreenDC := GetDC(0);
MyBitmap.LoadFromDevice(ScreenDC);
ReleaseDC(ScreenDC);
cheers,
Paul
Bookmarks