This is how I am sending email:
MailMessage m = new MailMessage();
m.From = new MailAddress("[email protected]", "Big Apps.");
m.To.Add(new MailAddress("[email protected]"));
m.Subject = "Test Subject";
m.Body = String.Format("This is Test email");
SmtpClient smtp = new SmtpClient();
smtp.Host = "smtp.gmail.com";
smtp.Port = 465;
smtp.EnableSsl = true;
smtp.Credentials = new System.Net.NetworkCredential()
{
UserName = "[email protected]",
Password = "mypassword"
};
smtp.EnableSsl = true;
smtp.Send(m);
Is there any setting that I need to enable in G Suite Admin? I need to send email from [email protected]