Q: Error : the remote certificate is invalid according to validation procedure im trying to make a simple app to send emails, using our local email server.
I always get this error no matter how i debug it.
Can anyone help? i've been stuck in this for days.
Thanks
my code
private void btnSendMail_Click(object sender, EventArgs e)
        {
            MailAddress from = new MailAddress("no-reply@mydomain.com.ph");
            MailAddress to = new MailAddress(tbRecepient.Text.Trim());

            MailMessage message = new MailMessage(from, to)
            {
                Subject = tbSubject.Text.Trim(),
                Body = rtbBody.Text.Trim()
            };

            SmtpClient client = new SmtpClient("172.11.3.25", 25)
            {
                EnableSsl = true,
                Credentials = new NetworkCredential("example@mydomain.com.ph", "password@2020")
            };

            try
            {
                client.Send(message);
            }
            catch (Exception exc)
            {
                MessageBox.Show(exc.Message);
            }
        }

