电子邮件密送不发送 [英] email Bcc not sending
问题描述
你好, hello, 这篇关于电子邮件密送不发送的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
i有一段代码可以在用户重置他的passowrd后发送确认电子邮件
这里是我的代码:
< pre lang =c#> private static void confirmationEmail( string email, string customerName, string customerCode)
{
string messageBody = hello world;
string url = www.abc。 COM跨度>;
string hyperlink = < a href =' + url + '> + abc Distribution + < / A> 中跨度>;
NetworkCredential logininfo = new NetworkCredential( example1 @ automob.com, ********);
MailMessage msg = new MailMessage();
msg.From = new MailAddress( communications@abc.com跨度>);
msg.To.Add( new MailAddress(email));
msg.Bcc.Add( new MailAddress( example2@abc.com跨度>));
msg.Subject = 确认 - 您的密码已被更改!;
msg.Body = messageBody;
msg.IsBodyHtml = true ;
SmtpClient client = new SmtpClient( smtp .globetrotter.net跨度>);
client.EnableSsl = false ;
client.UseDefaultCredentials = false ;
client.Credentials = logininfo;
client.Send(msg);
}
i有2个问题:
1-大部分电子邮件都发送给用户垃圾邮件或者垃圾
2-不发送密送。
任何帮助都会非常感激。
谢谢 1)您不能对收件人的垃圾邮件保护软件和更改负责; 2)BCC地址可能不存在;使用有效的地址。您可以使用一些有效的地址和一些可用的邮件软件来检查所有内容。
对于BCC问题, this [ ^ ]可能会对您有所帮助。
i have a block of code to send a confirmation email after user resets his passowrd
here is my code:
private static void confirmationEmail(string email, string customerName, string customerCode)
{
string messageBody = "hello world";
string url = "www.abc.com";
string hyperlink = "<a href='" + url + "'>" + " abc Distribution" + "</a>";
NetworkCredential logininfo = new NetworkCredential("example1@automob.com", "********");
MailMessage msg = new MailMessage();
msg.From = new MailAddress("communications@abc.com");
msg.To.Add(new MailAddress(email));
msg.Bcc.Add(new MailAddress("example2@abc.com"));
msg.Subject = "Confirmation - Your password has been changed!";
msg.Body = messageBody;
msg.IsBodyHtml = true;
SmtpClient client = new SmtpClient("smtp.globetrotter.net");
client.EnableSsl = false;
client.UseDefaultCredentials = false;
client.Credentials = logininfo;
client.Send(msg);
}
i have 2 problems:
1- most of the emails go to users spam or junk
2- is not sending Bcc.
any help would be much appreciated.
Thank you1) You cannot be held responsible for recipient's spam protection software and change; 2) the BCC address might not exist; use the address which works. You can check up everything using some valid addresses and some available mail software.
For the BCC issue, this[^] might help you.