Issue with CDO using ASP

Discussion in 'Email' started by Randrew, Dec 7, 2014.

  1. Setup ASP code according to KB article (https://support.Winhost.com/kb/a617/how-to-send-mail-using-cdo.aspx) but still getting "CDO.Message.1 error '80040213' The transport failed to connect to the server.
    /arm_web/app/emailprocessor.asp, line 132" error. Here is my code (password changed but confirmed that it was correct) I am testing from my local environment connected to the internet.

    set objMessage = createobject("cdo.message")
    set objConfig = createobject("cdo.configuration")
    Set Flds = objConfig.Fields
    Flds.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
    Flds.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") ="mail.animalrescuemanager.org"
    Flds.Item ("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
    Flds.Item ("http://schemas.microsoft.com/cdo/configuration/sendusername") ="[email protected]"
    Flds.Item ("http://schemas.microsoft.com/cdo/configuration/sendpassword") ="mypassword"
    Flds.update
    Set objMessage.Configuration = objConfig
    objMessage.To = "[email protected]"
    objMessage.BCC = "[email protected]"
    objMessage.From = "[email protected]"
    objMessage.Subject = "Test Email"
    objMessage.fields.update
    objMessage.HTMLBody = "This is a test sent from CDO using smtp authentication."
    objMessage.Send

    Any help is appreciated!
     
    Last edited by a moderator: Oct 14, 2015
  2. Elshadriel

    Elshadriel Winhost Staff

    Do you have a firewall enabled in your local environment? It might be blocking port 25.
     
    Michael likes this.
  3. my web server is a virtual 2008r2(sp1) and the firewall is turned off. enabled pot 25 on my dev machine (win7Ultimate,sp1) and still no luck - the VM's run on my dev machine...
     
  4. I moved my code out to the live site to test and it works fine. Im ok with that. Thanks for the help!
     
    Michael and Elshadriel like this.

Share This Page