Newsgroups : Borland : borland.public.delphi.internet.winsock : 2005 May : Need a bit of help

www.cryer.info
Managed Newsgroup Archive

Need a bit of help

Subject:Need a bit of help
Posted by:"xtcsuk" (xtcsuk..@yahoo.co.uk)
Date:Sun, 1 May 2005 19:27:05

I am trying to implement the scenario:
Client

{other code}
Client.Connect
Client.Writeln('Test');
if Client.ReadLn() = 'Send' then
Stream := TStringStream.Create('Some text');
Client.OpenWriteBuffer();
Client.SendStream(Stream);
Client.CloseWriteBuffer;
{other code}

Server

if aThread.Connection.ReadLn() = 'Test' then
aThread.Connection.Writeln('Test');
aThread.Connection.ReadStream(Stream, -1, False) {this is where it all goes
wrong}
{other code}

Can someone points me to the right direction here.

regards

Replies:

www.cryer.info
Managed Newsgroup Archive