解决方案 »
- gridview分页设置好以后,希望只有一页的时候页显示分页栏怎么设置
- 关于dropdownList的问题 ,看题目,求教求教了! 紧急
- AspNetPager控件的分页怎么弄
- ajax 控件Accordion没有效果
- asp.net2.0的treeview使用checkbox进行级联选择用javascript实现了,但是怎么在脚本中把选中的节点值取出来?
- C# 数据库查询的问题
- 求如何知道某一年某一月的一号是星期几(C#),急……在线等,解决就结贴
- vs2005中Wizard控件的問題!!!
- 遍历页面所有选中checkbox控件
- 请教一个关于datagrid的问题
- GridView表动态绑定列名,
- winform开发怎么使用三层架构??
public void SendMail(string formaddr, string formpros, string Encod, string toaddr, string topros, string server, string username, string password, string title, string body)
{
MailMessage message = new MailMessage(new MailAddress(formaddr, formpros, Encoding.GetEncoding(Encod)), new MailAddress(toaddr, topros, Encoding.GetEncoding(Encod)));
SmtpClient client = new SmtpClient(server);
NetworkCredential credential = new NetworkCredential(username, password);
message.Subject = title;
message.Body = body;
message.BodyEncoding = Encoding.GetEncoding(Encod);
message.SubjectEncoding = Encoding.GetEncoding(Encod);
message.IsBodyHtml = true;
client.Credentials = credential;
try
{
client.Send(message);
}
catch (SmtpFailedRecipientException exception)
{
throw new Exception(exception.Message, exception);
}
}