+1 vote

We have sent and received emails through this "Outlook Express" for years and need to check our email today if that is possible.

by

1 Answer

0 votes

Mail.dll is POP3 and IMAP component, if the email server on which you host your email account provides IMAP or POP3 access (which is almost sure), it is
possible.

The code that you can use in .NET to receive emails with IMAP looks as follows:

using(Imap imap = new Imap())
{
    imap.Connect("imap.server.com");  // or ConnectSSL for SSL
    imap.UseBestLogin("user", "password");

    imap.SelectInbox();
    List<long> uids = imap.Search(Flag.Unseen);
    foreach (long uid in uids)
    {
        IMail email = new MailBuilder()
            .CreateFromEml(imap.GetMessageByUID(uid));
        string subject = email.Subject;
    }
    imap.Close();
}

For details - take a look at this article:
https://www.limilabs.com/blog/receive-unseen-emails-using-imap

by (297k points)
...