NetworkCredential smtpCreds = new NetworkCredential("xxx@gmail.com", "senderspassword"); SmtpClient smtp = new SmtpClient("smtp.gmail.com", 25); smtp.EnableSsl = true; smtp.Credentials = smtpCreds; //smtp.Credentials = new NetworkCredential(TextBox1.Text, TextBox1.Text); MailMessage mail = new MailMessage("xxx@gmail.com", Emailtxt.Text, "Registration Details", bodytxt.Text); smtp.Send(mail);
smtp.send(mail);
remote connection not correct or not found
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)