Huch? There's method WSocket1DataAvailable that receives data
and SendButtonClick that sends strings.

There is no such button "SendButtonClick" in this project --> OverbyteIcsSrvTcp.bdsproj.
Are we talking about the same project or is it something which I don't have?


TCP/IP requires a connection before data can be sent or received.
A client has to connect to the server first.

Absolutely.


This method triggers whenever data sent by the server is received.

But wait, I just found and fixed a bug in OverbyteIcsCli7 that was introduced
during the Unicode conversion. Exchange function RemoveEndOfLine by :

function RemoveEndOfLine(const Line : String) : String;
begin
   if (Length(Line) >= Length(EndOfLine)) and
      (StrLComp(PChar(@Line[1 + Length(Line) - Length(EndOfLine)]),
                PChar(EndOfLine),
                Length(EndOfLine)) = 0) then
       Result := Copy(Line, 1, Length(Line) - Length(EndOfLine))
   else
       Result := Line;
end;


This has fixed the error :)
I can now send from client to the server.

But,
I still can't send anything from server to the client.
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to