string strSmtpServer = "smtp.163.com";//郵箱的SMTP服務器
string strFrom = " ### "; //寫發送郵件的郵箱
string strFromPass = " ### ";//郵箱的密碼
string strto = this.TextBox1.Text ;//(輸入郵箱的文本框)
string strSubject = TextBox2.Text;
string strBody = CKeditor .Text;//(郵箱的正文內容)
System.Net.Mail.SmtpClient client = new SmtpClient(strSmtpServer);
client.UseDefaultCredentials = true;
client.Credentials = new System.Net.NetworkCredential(strFrom, strFromPass);
client.DeliveryMethod = SmtpDeliveryMethod.Network;
System.Net.Mail.MailMessage message = new MailMessage(strFrom, strto, strSubject, strBody);
message.BodyEncoding = System.Text.Encoding.UTF8;
message.IsBodyHtml = true;
client.Send(message);