如何通过smtp发送电子邮件作为gmail对话的一部分?采取相同的主题不起作用......
告诉我你是否需要更多信息...提前感谢!
MailMessage mail = new MailMessage();
SmtpClient SmtpServer = new SmtpClient("smtp.gmail.com");
mail.From = new MailAddress("@googlemail.com");
mail.To.Add("@.com");
mail.Subject = "(Somee.com notification) New order confirmation";
mail.Body = "(Somee.com notification) New order confirmation";
SmtpServer.Port = 587;
SmtpServer.Credentials = new System.Net.NetworkCredential("", "");
SmtpServer.EnableSsl = true;
SmtpServer.Send(mail);
Run Code Online (Sandbox Code Playgroud)
您需要使用以下内容:
mail.Headers.Add("In-Reply-To", <messageid>);
Run Code Online (Sandbox Code Playgroud)
您应该能够从之前的电子邮件标题中获取的消息ID.只需查找"Message-Id"即可.
这个答案提供了一些您可能想要添加的标题,以便在其他客户端中尝试帮助线程.似乎gmail现在也在使用它们.
| 归档时间: |
|
| 查看次数: |
735 次 |
| 最近记录: |