G
Guest
I recently upgraded my application from VB6, and was using the Winsock
control. In VB2005 I am using the TcpListener Class and have managed to get
it working, except for one thing:
Is there a way for the server to detect when a client disconnects (i.e.
closes the program abruptly)? In VB6 the Winsock control had the Close event,
which would fire when the client disconnected.
Some suggest that it can be done by sending a message to the client at
regular intervals (heartbeat) to check for connectivity, but I would rather
not have to do this.
Is there a method for when the client disconnects?
control. In VB2005 I am using the TcpListener Class and have managed to get
it working, except for one thing:
Is there a way for the server to detect when a client disconnects (i.e.
closes the program abruptly)? In VB6 the Winsock control had the Close event,
which would fire when the client disconnected.
Some suggest that it can be done by sending a message to the client at
regular intervals (heartbeat) to check for connectivity, but I would rather
not have to do this.
Is there a method for when the client disconnects?