无法检索特定的邮件服务器..可能的原因电子邮件文件夹邮件服务器、文件夹、电子邮件、原因

2023-09-07 08:51:57 作者:被猪拱的小白菜

我没有使用ImapX取回我的电子邮件帐户的文件夹:

I am failing to retrieve the folders of my email account using ImapX:

 ImapX.ImapClient m_ImapClient = new ImapX.ImapClient( ImapServerAddress, (int) ImapServerPort, System.Security.Authentication.SslProtocols.Ssl3, false);
 m_ImapClient.Connect();
 m_ImapClient.Login( EmailAddress, EmailPassword);
//the two functions above each return true
//this last statement throws an exception:
ImapX.Collections.FolderCollection vFolders = m_ImapClient.Folders;

是:

'm_ImapClient.Folders' threw an exception of type 'System.NullReferenceException' ImapX.Collections.CommonFolderCollection {System.NullReferenceException}

什么是错,我使用IMAP,SSL,端口993 ImapX 2,本工程为imap.google.com在993,但对于其他网络服务器不工作..为什么这可能发生的任何想法?

What's wrong, I'm using IMAP, ssl, port 993. ImapX 2. This works for imap.google.com on 993, but doesn't work for another network server.. Any ideas of why this could happen?

推荐答案

此问题已得到修复,谢谢!有关详细信息,请参阅问题:无法在IMAP服务器全成登陆后得到邮件文件夹。问题发生在解析了约文件夹IMAPX服务器返回的信息。某些服务器不引用的文件夹名称。

This issue has been fixed, thank you! For details see Issue: Unable to get mail folders after successfull login on IMAP server. The problem occured on parsing the information returned by the IMAPX server about folders. Some servers do not quote the folder names.