C# SMTP email sending code fails for Yahoo Mail but works fine for other servers, can anyone help?

后端 未结 5 2117
孤城傲影
孤城傲影 2020-12-16 23:26

I am using this code to send an SMTP email via the yahoo SMTP server, it is for a personal project I am writing.

using System.Net.Mail;
using System.Net;

Sm         


        
5条回答
  •  长情又很酷
    2020-12-16 23:38

    It's not supported through 465, but the following post details a workaround

    How can I send emails through SSL SMTP with the .NET Framework?

    UPDATE: This link details why it might work through Outlook Express, but not through the System.Net.Mail

    http://blogs.msdn.com/b/webdav_101/archive/2008/06/02/system-net-mail-with-ssl-to-authenticate-against-port-465.aspx

提交回复
热议问题