Skip to content

Instantly share code, notes, and snippets.

@ademar
Last active November 5, 2019 08:51
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save ademar/8443249 to your computer and use it in GitHub Desktop.
Save ademar/8443249 to your computer and use it in GitHub Desktop.
CDO enable ssl
set cdoMessage = Server.CreateObject("CDO.Message")
set cdoConfig = Server.CreateObject("CDO.Configuration")
cdoConfig.Fields("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = 1
cdoConfig.Fields("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
cdoConfig.Fields("http://schemas.microsoft.com/cdo/configuration/smtpserver") = smtpServer
if needToAuth then
cdoConfig.Fields("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
cdoConfig.Fields("http://schemas.microsoft.com/cdo/configuration/sendusername") = userName
cdoConfig.Fields("http://schemas.microsoft.com/cdo/configuration/sendpassword") = password
end if
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment