> IMO the component should clear LastResponse on before connect.
Maybe it should, but what it does is different story :)
The following fails also with non-sync version but sync is easier to copy-paste.
//------------------------------
SyncPop3Cli->Host = "put-valid-server-here";
SyncPop3Cli->UserName = "put-valid-username";
SyncPop3Cli->PassWord = "put-valid-password";
SyncPop3Cli->ConnectSync();
SyncPop3Cli->UserSync();
SyncPop3Cli->PassSync();
SyncPop3Cli->StatSync();
SyncPop3Cli->QuitSync();
// Here you should have "+OK goodbye" or whatever in LastResponse
MessageBox(NULL,("LastResponse:"+SyncPop3Cli->LastResponse+"\r\nLastError:"+
SyncPop3Cli->ErrorMessage).c_str(), "Info", MB_OK);
SyncPop3Cli->ClearErrorMessage();
//SyncPop3Cli->LastResponse = ""; // What should be done
SyncPop3Cli->Host = "www.google.com"; // Simulate bad server
SyncPop3Cli->Port = 81; // Behind firewall
SyncPop3Cli->UserName = "a";
SyncPop3Cli->PassWord = "b";
SyncPop3Cli->ConnectSync();
// "+OK goodbye" from last connection is still here
MessageBox(NULL,("LastResponse:"+SyncPop3Cli->LastResponse+"\r\nLastError:"+
SyncPop3Cli->ErrorMessage).c_str(), "Info", MB_OK);
//------------------------------
> So what about a numeric property LastErrorNumber?
There is no such property nowhere in pop3 (or in any ICS file).
> something, worth to be tested anyway:
> [...]
I'll take a look and test this code soon enough. Thanks.
--
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