so here is my code:
protected void BtnSubmit_Click(object sender, EventArgs e)
{
MailMessage msg = new MailMessage();
msg.From = new MailAddress("[email protected]","Kamal");
msg.To.Add(TxtEmailPass.Text);
msg.Subject = "Forget Password!";
msg.Body = "your password is:";
SmtpClient mySmtpClient = new SmtpClient();
mySmtpClient.Host = "www.Hotmail.com";
NetworkCredential nc = new NetworkCredential();
nc.UserName = "[email protected]";
nc.Password = "";
mySmtpClient.UseDefaultCredentials = true;
mySmtpClient.Credentials = nc;
mySmtpClient.Port = 587;
mySmtpClient.EnableSsl = true;
mySmtpClient.Send(msg);
}
it keeps telling me that
"No connection could be made because the target machine actively refused it 157.56.198.204:587"
anyone can help me with this?