什么是smartermail?如何通过服务器上安装的smartermail发送邮件? web.config中的任何smtp设置?
答案 0 :(得分:3)
SmarterMail是SMTP邮件服务器,因此您可以使用SmtpClient类发送邮件:
var client = new SmtpClient("hostnameOfYourSmtpServer");
var from = new MailAddress("from@example.com");
var to = new MailAddress("to@example.com");
var message = new MailMessage(from, to);
message.Subject = "test subject";
message.Body = "This is a test e-mail message sent by an application. ";
client.Send(message);