Well, I would like to thank to all of you tried to help me. I have found 
the way how to manage a buffer in TWSchat1.pas (Thank you, Francois).
BTW I would prefer to use Linemode too but I am not allowed to write TCP 
client by myself, it's a part of delivered software.

FYI, every packet i obtain to server has a header:

THeader = record

Command can be "read", "write" or "notify".
Length is probably clear :-)
The client application uses channels for data. Channels can be any type 
  (bit, byte, word, integer, float, etc.
The group of channels has to be the same type, if the type is "string" 
there is allowed to be one channel in the header only.

If the command is "read" the rest of packet (or some nexts) keeps values 
of announced channels, if "write" the client send the header only and is 
awaiting values of demanding channels (together with the header) and if 
command is "notify" it means channels will be changed in short time and 
it's up to you what to do (it's mean "to be prepared to deliver new 
values ASAP to the second side"}.

I consider it should be best solution to wait for full record in 
OnDataAvailable procedure, to do a new record and send some USER 
message. Am I right?

Thank again

To unsubscribe or change your settings for TWSocket mailing list
please goto http://www.elists.org/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to