重定向页面。
Msg.IsBodyHtml = true;
Msg.CC.Add(dig);
Msg.CC.Add(sp);
Msg.CC.Add(dsp);
// your remote SMTP server IP.
SmtpClient smtp = new SmtpClient();
smtp.Host = ConfigurationManager.AppSettings["smtpServer"];
smtp.Port = Convert.ToInt32(ConfigurationManager.AppSettings["smtpPort"]);
smtp.EnableSsl = true;
smtp.Credentials = new System.Net.NetworkCredential(ConfigurationManager.AppSettings["smtpUser"], ConfigurationManager.AppSettings["smtpPass"]);
// smtp.EnableSsl = true;
smtp.Send(Msg);
Response.Redirect("AccusedProfile.aspx?AccusedId=" + idLbl.Text + "&Success=Y"); //This line is not executing.
如何在发送电子邮件后执行重定向?