Hello! >>> This is how winsock works. OnSessionConnected is fired with an error, >>> after it OnSessionClosed is fired with or without an error.
>> So having TWSocket's state different from actual state should be >> considered >> normal? If so, then I understand that checking for component state is NOT >> enough to check whether it is actually connected or not? > Well, you should probably consider you are connected with error. The error > code being available thru the OnSessionConnected event. So how should I handle connection errors in a way that makes user aware of error AND not cause any kind of disaster? Catch the error code in OnSessionConnected and (using some kind of PostMessage) display actual error message outside OnSessionConnected? -- Piotr Dałek enigmati...@interia.pl ------------------------------------------------- Dzwon tanio! Sprawdz >> http://linkint.pl/f29a1 -- 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