gpt4 book ai didi

c# - goDaddy SMTP-无法从传输连接 : net_io_connectionclosed 读取数据

转载 作者:行者123 更新时间:2023-11-30 20:23:54 42 4
gpt4 key购买 nike

我正在尝试使用 goDaddy smtp 服务器设置邮件功能,Go daddy 支持在这里也不是很有用。

我试过这些服务器:

relay-hosting.secureserver.net - 错误 - 无法连接\

smtpout.secureserver.net - 错误 - 无法从传输连接读取数据:net_io_connectionclosed

goDaddy 是这样说的:

enter image description here

这是我的代码片段:

MailMessage mail = new MailMessage("signup@xxx-xxx.com", to);
SmtpClient client = new SmtpClient();
client.Host = "smtpout.asia.secureserver.net";
//Tried "relay-hosting.secureserver.net" -Errors-Unable to connect
//Tried "smtpout.secureserver.net" -Errors-Unable to read data from the transport connection: net_io_connectionclosed
client.Port = 25;
//Tried 80, 3535, 25, 465 (SSL)
client.UseDefaultCredentials = false;
client.DeliveryMethod = SmtpDeliveryMethod.Network;
client.EnableSsl = false;
client.ServicePoint.MaxIdleTime = 1;
client.Timeout = 1000;
client.Credentials = new NetworkCredential("signup@xxx-xxx.com", "xxx-xxx");
mail.IsBodyHtml = true;
mail.Subject = "xxx-xxx.com Account Activation";

mail.Body = SomeBigHTMLstring;
client.Send(mail);
mail.Dispose();

这是我得到的错误页面

enter image description here enter image description here

伙计们帮帮我。

最佳答案

问题解决后,您可以使用端口号:3535 和 EnableSSL:false...

MailMessage mail = new MailMessage("signup@xxx-xxx.com", to);
SmtpClient client = new SmtpClient();
client.Host = "smtpout.asia.secureserver.net";

// Tried "relay-hosting.secureserver.net" -Errors-Unable to connect
// Tried "smtpout.secureserver.net" -Errors-Unable to read data from
// the transport connection: net_io_connectionclosed

client.Port = 3535; //Tried 80, 3535, 25, 465 (SSL)
client.UseDefaultCredentials = false;
client.DeliveryMethod = SmtpDeliveryMethod.Network;
client.EnableSsl = false;
client.ServicePoint.MaxIdleTime = 1;
client.Timeout = 1000;
client.Credentials = new NetworkCredential("signup@xxx-xxx.com", "xxx-xxx");
mail.IsBodyHtml = true;
mail.Subject = "xxx-xxx.com Account Activation";
mail.Body = SomeBigHTMLstring;
client.Send(mail);
mail.Dispose();

快乐编码...:-)

关于c# - goDaddy SMTP-无法从传输连接 : net_io_connectionclosed 读取数据,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27763539/

42 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com