> I have been trying to use the IP (PEERADDR) and the port (PEERPORT) > in this, > SslWSocketServer1.Client[0].SendStr(ledSendCommand.Text + #13 + > #10); for trying to send with no success. > The command is gonna be typed into a "TLabelEdit" component which > is text and sending requires integer and I still can't find the way > of handling it.
Sorry, but you really are out of your depth here, you need to understand simple programming first. We can not write your programme for you. However, you have to find the client number that matches the IP address and port, by using a loop. clientnr := -1 ; for I := 0 to SslWSocketServer1.ClientCount do begin if SslWSocketServer1.Client[I].GetPeerAddr = MyPeerAddr and SslWSocketServer1.Client[I].GetPeerPort = MyPeerPort then begin clientnr := I; // found it break; end; end; if clientnr >= 0 then SslWSocketServer1.Client[clientnr].SendStr (etc) MyPeerAddr and Port come from a table you saved earlier when each connection was started. The code above is not very efficient, there is an overhead to GetPeerPort, so you should really save them as a derived ClientClass, exactly as the FTP server does, look at the code. Angus -- 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