I need to be able to send the commands from the server to the client as
well.
Given a server has a lot of client (potentially), how do you select the
client you want to communicate with ?
Usually a server reply to a command sent by a client, but once the client is
connected, the server can send anything to the client, even without any
prior request by the client.
I can find nothing about how to send anything from server to the selected
client.
Assuming N is the index of the selected client, you send something using
this line of code:
WSocketServer.Client[N].Send(MyBufAddr, MyBufLnegth);
When sending something back to a client having sent a command, you use the
sender argument of the dataavailable event. This sender represent the
client:
TWSocket(Sender).Send(MyBufAddr, MyBufLnegth);
--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be
--
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