我正在使用下面的代码;以下几点之一可能是错误的原因,但我不知道;
1-应用程序在开发机器上 2-当应用程序在本地主机上运行时,smtp ip 托管在服务器上
我收到此错误“邮箱不可用。服务器响应为:5.7.1 无法中继 mhtbusoum@gmail.com”;
Dim message As New MailMessage
message.From = New MailAddress(Strings.LCase("mhtbusoum@mysite.com"))
message.To.Add("mhtbusoum@gmail.com")
message.IsBodyHtml = True
message.Priority = MailPriority.Normal
message.Subject = ("Testing SmtpClient email sending")
message.Body = ("It is to test the email sending without any password")
Dim client As New SmtpClient("mailSending.actualSite.com", 25)
client.UseDefaultCredentials = False
client.Send(message)