Thursday, March 19, 2009

 

Transferring objects over the network (Part II)


Here is the sample code and executables for Transferring Objects Over the Network.

Click here to download.

Edit: If the above url doesn't work due to Geocities limitations. Please, download the file from this link.

Comments:
El link no esta funcionando.
 
Too much downloads for my GeoCities account. You have to wait a couple of minutes and try again.

BTW, does anybody recommends a free service to host files?. I don't know how to upload files to my blogger account.

Leonardo.
 
try www.rapidshare.com
 
Thanks, but as Rapidshare files are removed after a while, it is not an option.
 
What about http://code.google.com/ ?
 
Great idea Jan!.
 
Post it on CodeCentral

http://cc.embarcadero.com/add
 
Thanks Lachlan, I added the post to CodeCentral.
 
Hi Leonardo,

Would you have a working version on Delphi 2007 + Indy 10.1.5 ? seems like Indy has changed some methods and object properties.

Regards,
Mocte
 
Can't see my comment, well if you have sources working with Indy 10.1.5 please let me know

--
Mocte
 
Sorry Mocte, I didn't tested with Indy 10. But, this code is easy enough to be adapted to Indy 10 and Synapse also.
 
Thanks for answering Leonardo, I figured it out, the relevant lines I have changed were,

On the server side :

lCommand := AThread.Connection.ReadLn;

to:

lCommand := AContext.Connection.IOHandler.ReadLn;


and

AThread.Connection.WriteStream(lStream, True, True, lStream.Size);

to:
AContext.Connection.IOHandler.Write(lStream, lStream.Size, True);


On client side :

(* Send command to server *)
IdTCPClient1.WriteLn('LOADCUSTOMERS');
(* Read the server's response *)
IdTCPClient1.ReadStream(lStream);


to:

(* Send command to server *)
IdTCPClient1.IOHandler.WriteLn('LOADCUSTOMERS');
(* Read the server's response *)
IdTCPClient1.IOHandler.ReadStream(lStream);


Regards,
Mocte
 
Hello,

I have a message for the webmaster/admin here at www.blogger.com.

Can I use part of the information from this blog post right above if I provide a link back to your site?

Thanks,
Oliver
 
Yes Oliver, go ahead. When your article is published, please let me know.
 
Both the links above are uncorrect and I cannot find the source code in codecentral.

Please instruct.

Thank you

Duilio
 
Hi Duilio, here is the link in CodeCentral:

http://cc.embarcadero.com/Item/26747

Regards,
Leonardo.
 
Hello there,

I have a message for the webmaster/admin here at leonardorame.blogspot.com.

Can I use some of the information from your blog post above if I provide a link back to this site?

Thanks,
James
 
James, yes, go ahead.
 
Hi there,

Thanks for sharing this link - but unfortunately it seems to be down? Does anybody here at leonardorame.blogspot.com have a mirror or another source?


Thanks,
Oliver
 
Hi - I am definitely glad to find this. Good job!
 
Post a Comment



<< Home

This page is powered by Blogger. Isn't yours?