Multithreaded server, send data independently?
<p>I'm trying to build a simple multithreaded tcp server. The client connects and sends data to server, the server responds and waits for data again. The problem is I need the server to listen for incoming data in separate thread and be able to send command to client any time (for example to notify about new update). As far as I understood, when ever client sends data to server, if server doesn't respond with any data, client app doesn't let me send more data, server simply doesn't receive them. If I send data ether way around, does the data need to be 'acknowledged' for tcpclient?</p>

<p>Here's the source for the server: <a href="http://csharp.net-informations.com/communications/files/print/csharp-multi-threaded-server-socket_print.htm" rel="nofollow">http://csharp.net-informations.com/communications/files/print/csharp-multi-threaded-server-socket_print.htm</a></p>

<p>How can I make the server send command to a client in separate thread outside the "DoChat" functions loop? or do I have to handle everything in that thread? Do I have to respond to each request client sends me? Thanks!</p>
