Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
Can you pls give some idea to fix this
Error: The message could not be sent to the SMTP server. The transport error code was 0x80040217. The server response was not available
My Macro is
Sub SendGMail()
' Object creation
Set objMsg = CreateObject("CDO.Message")
Set msgConf = CreateObject("CDO.Configuration")
' Server Configuration
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "smtp.gmail.com"
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 465
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = "****@gmail.com"
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = "*****"
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = 443
msgConf.Fields.Update
objMsg.To = "****@gmail.com"
objMsg.From = "****@gmail.com"
objMsg.Subject = "Test send with Gmail account"
objMsg.HTMLBody = "HTML/Plain text message."
objMsg.Sender = "Mr. Name"
Set objMsg.Configuration = msgConf
' Send
objMsg.Send
' Clear
Set objMsg = nothing
Set msgConf = nothing
End Sub
Tnaks,
Keke
Log in with that account in Google Mail, then go to https://myaccount.google.com/lesssecureapps and set Less Secure to "On".
Try this
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "smtp.gmail.com"
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = "****@gmail.com"
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = "*****"
msgConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = true
Hi,
Error: The transport failed to connect to the server.
Hi,
Its already 'On' but its not working
Does the account have two step verification enabled?
Sry, how to find that
Strangely enough. Try to check login and password.