0
我收到以下錯誤發送電子郵件:無法通過本地主機
Failure sending mail
和內部異常是
Unable to connect to the remote server
在C#
MailMessage mail = new MailMessage("[email protected]", "[email protected]","Newsletter", "This is a test mail");
SmtpClient client = new SmtpClient("localhost");
client.Send(mail);
這是我的本地SMTP電子郵件設置在IIS 7中。
還安裝了SMTP服務器工具
是實際運行的smtp服務嗎? –
我沒有看到任何服務。我在哪裏開始smtp服務? –
可能在某處iis管理器中。 –