Email sending source code
no vote
&Nbsp; try & nbsp; & nbsp; & nbsp; {& nbsp; & nbsp; / / the temporary mandatory code is GB2312 & nbsp; & nbsp; encoding encoding= Encoding.GetEncoding (936); & nbsp; & nbsp; mailmessage message = new mailmessage & nbsp; & nbsp; new MailAddress & quot;, & quot; 5 & quot;, encoding), / / the first parameter is the address of the sender, and the second parameter is the sender & nbsp; &Nbsp; new MailAddress (textbox1. Text)); / / recipient email & nbsp; & nbsp; Message.SubjectEncoding = encoding; Message.Subject =Textbox2. Text; / / Title & nbsp; & nbsp; Message.BodyEncoding = encoding; Message.Body =Textbox3. Text; / / subject & nbsp; & nbsp; smtpclient smtpclient = new smtpclient (& quot; SMTP. 163. Com & quot; ); / / mailbox server & nbsp; & nbsp; smtpClient.Credentials =New networkcredential & quot; your mailbox user name & quot;, & quot; your mailbox password & quot;); / / your mailbox user name and password & nbsp; & nbsp; smtpClient.Timeout = 999999; smtpClient.Send (Message); } catch (Exception ex) { throw new