A few POP3 related questions... 1. How am I supposed to detect when POP3 component has disconnected or what state is it in?
OnSessionClosed appears to trigger BEFORE it disconnects but after QUIT is sent (not logical for me, should be the last one to trigger) and what seems to trigger at the disconnection time is OnRequestDone when TPop3Request is pop3Quit which appears to be the last one to happen. But if I immediately during this event start new batch of POP3 commands (by setting new server, new port etc.) it may sometimes trigger "pop3 already connected" and sometimes won't. So obviously it is still connected. Also, is it good to fill pop3 component with new server name while in event handler or how to implement a small time-delay (to fill it right after the event is handled)? Next I tried OnStateChange event. It is supposed to update SyncPop3Cli1->State or perhaps ProtocolState right? Well... it does trigger but SyncPop3Cli1->State always returns pop3Ready (defined as 0). Same goes for SyncPop3Cli1->ProtocolState - whenever I read it it always says pop3Disconnected. So why these are not updated or how to read them? Finally, I tried SyncPop3Cli1->Connected - which always returns true. I could start 2-3 pop3 components for 2-3 servers rather than waiting for first one to finish, but that is rather dumb idea if protocol state can be detected. 2. What good is TimeOut property for? It is obviously not for timeout like for example waiting for server response because you have to use TTimer for that. I also tried to see if it will be used for DNS lookup or something like that but it doesn't seem to have any effect... -- 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