Re: Sending email error - SMTP Server requires a secure connection 5.5.1
Check this linkhttp://stackoverflow.com/questions/704636/sending-email-through-gmail-smtp-server-with-c-sharpThe first answer works well... I've tested it myself
View ArticleRe: Sending email error - SMTP Server requires a secure connection 5.5.1
Still same problem ? same error message
View ArticleRe: Sending email error - SMTP Server requires a secure connection 5.5.1
Remove it from your code behind
View ArticleRe: Sending email error - SMTP Server requires a secure connection 5.5.1
my question is why I am defining gmail username, password, port, mail server etc twice ? in code behing ad well as in webconfig ?
View ArticleRe: Sending email error - SMTP Server requires a secure connection 5.5.1
try editing your web config file and adding this<system.net><mailSettings><smtp from="fromEmail" deliveryMethod="Network"><network defaultCredentials="false" enableSsl="true"...
View ArticleRe: Sending email error - SMTP Server requires a secure connection 5.5.1
This is my code (added the above line) but still getting same error:protected void Button1_Click(object sender, EventArgs e) { // Create a message and set up the recipients. SmtpClient smtpClient = new...
View ArticleRe: Sending email error - SMTP Server requires a secure connection 5.5.1
There are some weird exceptions when the delivery method is not set explicitly. Please try this and see if it works. This should be added to your updated code
View ArticleRe: Sending email error - SMTP Server requires a secure connection 5.5.1
try adding this under smtpclient instantiationsmtpclient.deliverymethod = smtpdeliverymethod.network
View ArticleRe: Sending email error - SMTP Server requires a secure connection 5.5.1
This is my new updated code:protected void Button1_Click(object sender, EventArgs e) { // Create a message and set up the recipients. SmtpClient smtpClient = new SmtpClient(); MailMessage message = new...
View ArticleRe: Sending email error - SMTP Server requires a secure connection 5.5.1
Try adding this. It is by no means a solution to the problem but if it works it may help us work out what is wrong with the original setup (add all of this at the end just before the smptClient.send...
View ArticleSending email error - SMTP Server requires a secure connection 5.5.1
I have this in my webconfig:<mailSettings><smtp from="mygmailadd@gmail.com"><network host="smtp.gmail.com" password="gmailpassword" port="587" userName="mygmailadd@gmail.com"...
View Article