I have a server where I send and receive messages, create an app from C # where I can send emails but do not recognize the credentials that I tell you, they tell me they are false:
correo = new MailMessage();
correo.To.Add(new MailAddress(this.to));
correo.From = new MailAddress("[email protected]");
correo.Subject = subject;
correo.Body ="";
correo.IsBodyHtml = false;
SmtpClient client = new SmtpClient("web.local.com", 443);
using (client)
{
client.Credentials = new NetworkCredential("[email protected]", "xxxx");
client.EnableSsl = true;
client.Send(correo);
}
try
{
correo.Dispose();
MessageBox.Show("Email was successfully sent. ", "", MessageBoxButtons.OK, MessageBoxIcon.Information);
}
catch (Exception ex)
{
MessageBox.Show("Error sending email. " + ex, "", MessageBoxButtons.OK, MessageBoxIcon.None);
}
I do not know if other ports are used because they are local. The problem is that the user does not recognize.