Karamja
asked on
Remote Screen
Hello, I need a client and server program where you can see the desktop of where the server is running.
I need an example.
Thx Karamja
{ Note: I will give upto 735 points but dew to limit I can only put 500, I will give you the rest of the points in a diff question }
I need an example.
Thx Karamja
{ Note: I will give upto 735 points but dew to limit I can only put 500, I will give you the rest of the points in a diff question }
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
You can download at www.alsantos.kit.net/remotescreen.rar
ASKER
That url dont work? lol, Could you e-mail it to webmaster@express-hosting. co.uk
ASKER
Thx, Sorry about the uploading and e-mail stuff
Thanks too. :)
alsantos
alsantos
hmm, there is a memory-leak i guess
-> the result of the captureScreen-function is never freed
-> the result of the captureScreen-function is never freed
Yes.... sorry... put "Jpeg.Free;" after the savetostream
procedure TForm1.Button1Click(Sender : TObject);
var
msSend: TMemoryStream;
Jpeg: TJPEGImage;
begin
idClient.Port:=9090;
idClient.Host:='127.0.0.1' ;
idTCpServer1.DefaultPort:= 9090;
idTcpServer1.Active:=True;
idClient.Connect;
Jpeg := CaptureScreen;
msSend := TMemoryStream.Create;
Jpeg.SaveToStream(msSend); // jpeg.free after the savetostream
Jpeg.Free; // here
if idClient.Connected then
begin
idClient.WriteLn(IntToStr( msSend.Siz e));
idClient.WriteStream(msSen d);
end;
msSend.Free;
idClient.Disconnect;
end;
:)
alsantos
procedure TForm1.Button1Click(Sender
var
msSend: TMemoryStream;
Jpeg: TJPEGImage;
begin
idClient.Port:=9090;
idClient.Host:='127.0.0.1'
idTCpServer1.DefaultPort:=
idTcpServer1.Active:=True;
idClient.Connect;
Jpeg := CaptureScreen;
msSend := TMemoryStream.Create;
Jpeg.SaveToStream(msSend);
Jpeg.Free; // here
if idClient.Connected then
begin
idClient.WriteLn(IntToStr(
idClient.WriteStream(msSen
end;
msSend.Free;
idClient.Disconnect;
end;
:)
alsantos
Yep, better :-))
ASKER