Search code examples
c#emailimapyahoo

Connecting to yahoo email with IMAP4 MailSystem.NET


I try to connect to mail yahoo account from C# using net/imap MailSystem.NET. But I get error Stack OverFlow on imap.Login command

Anybody tries to connect to Yahoo! Mail and had some experiences about it with MailSystem.NET ?

Here's my working code.

Imap4Client imap = new Imap4Client();
imap.ConnectSsl("imap.mail.yahoo.com", 993);
imap.Login("[email protected]", "PWD");
imap.Command("capability");

Solution

  • I would like to suggest you to use ImapX

    I used it an manage to access Gmail yahoo etc.

    BTW- were you able to connect to another mail server like Gmail.com?