dluedi
asked on
Snapshot of desktop
How can I make a snapshot of the desktop with Delphi?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
asked on
You could download my TScreenGrab component from www.drdelphi.com OR
procedure TForm1.Button1Click(Sender
begin
grabdesktoprect(rect(0,0,S
end;
function TForm1.GrabDesktopRect(rec
var tempbmp:Tbitmap;
tempcanvas:Tcanvas;
begin
tempbmp:=TBitmap.create;
with tempbmp do
begin
height:=rect.bottom-rect.t
width:=rect.right-rect.lef
end;
tempcanvas:=TCanvas.create
TempCanvas.handle:= GetWindowDc(GetDeskTopwind
tempbmp.Canvas.CopyRect(re
tempbmp.savetofile(fname);
tempbmp.Free;
TempCanvas.free;
end;
end.
Your choice.
Good luck!!