它會在幾分鐘內發送2-8次。這不是一直髮生的,每次他們發送電子郵件給同一收件人時也不會發生;它似乎是隨機的。收件人收到發件人發送的多封電子郵件
我的郵箱代碼
SmtpClient oSmtpClient = new SmtpClient();
oSmtpClient.Port = oSmtpSection.Network.Port;
oSmtpClient.EnableSsl = bool.Parse(oSmtpSection.Network.EnableSsl.ToString());
oSmtpClient.UseDefaultCredentials = true;
oSmtpClient.Host = oSmtpSection.Network.Host;
oSmtpClient.Credentials = new NetworkCredential(oSmtpSection.Network.UserName, oSmtpSection.Network.Password);
//Add this line to bypass the certificate validation
System.Net.ServicePointManager.ServerCertificateValidationCallback = delegate(object s,
System.Security.Cryptography.X509Certificates.X509Certificate certificate,
System.Security.Cryptography.X509Certificates.X509Chain chain,
System.Net.Security.SslPolicyErrors sslPolicyErrors)
{
return true;
};
請幫助。
幾乎可以肯定的是,實際發生的事情是您發送多封電子郵件,但您只是沒有隔離如何或爲何發生這種情況。如果不是這樣,那麼接下來要看的是電子郵件系統中是否安裝了某些組件(如防病毒系統),並且配置不當。 –