Web Wiz - Solar Powered Eco Web Hosting

  New Posts New Posts RSS Feed - CDOSYS Error 8004020f
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CDOSYS Error 8004020f

 Post Reply Post Reply
Author
Electronomical View Drop Down
Newbie
Newbie


Joined: 13 October 2009
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote Electronomical Quote  Post ReplyReply Direct Link To This Post Topic: CDOSYS Error 8004020f
    Posted: 08 May 2011 at 7:23pm
Hi I am moving away a webform application from fasthosts and hav it installed on webwiz.

I tried using my apps jmail include but failed as it does not support smtp user and password.(which worked fine on fasthosts).

I have now moved to the apps CDOSYS include with some success. I have an SMTP mail acount set up which I can send and receive. I have added the parmeters to my apps config file and when I submit a form the script runs then fails on the last line with the  Error 8004020f.

I put an invalid smtp server address and the script bombs with an unable to connect error so I must have the server address correct. I have double checked the user and paswd. I an sure they are right.

I have changed the sendusing parameter from 2 to 1 and this turns up a new error at the last line so something is happening.

CDO.Message.1 error '80040222'

The pickup directory path is required and was not specified.

/absolutefp/incEmail.asp, line 26

Any ideas what I am doing wrong.

Please don't give me to much script jargon cos I know diddly squat about it and i am using a prewritten forms package called Absolutefp

This is my email script.

<%
'//// Include for CDOSYS ////
emailcomponent="CDOSYS"
sub sendmail(recipient,senderemail,subject,message)
    Set iConf = CreateObject ("CDO.Configuration" )
    Set Flds = iConf.Fields
    Flds("http://schemas.microsoft.com/cdo/configuration/smtpserver") = smtpserver
    Flds("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
    if smtpusr<>"" and smtppwd<>"" then
        Flds("http://schemas.microsoft.com/cdo/configuration/SMTPAuthenticate") = 1
        Flds("http://schemas.microsoft.com/cdo/configuration/SendUserName") = smtpusr
        Flds("http://schemas.microsoft.com/cdo/configuration/SendPassword") = smtppwd
    end if
    Flds.Update
    Set oMail= CreateObject("CDO.Message" )
    Set oMail.Configuration = iConf
    oMail.From = defaultemail
    if senderemail<>"" then
        oMail.From = senderemail
        omail.replyto = senderemail
    end if
    strTo=replace(recipient,vbcrlf,";")
    oMail.To = strTo   
    oMail.Subject = subject
    oMail.TextBody = message
    oMail.Send
    Set oMail = Nothing
end sub


%>


Any ideas.




 
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9791
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 09 May 2011 at 10:23am
You are able to use JMail on our servers, we have JMail 4 installed which does support authentication.

The error you have suggests that you are attempting to place the email in a pickup directly rather than sending the email across the network to the SMTP server.

The post below has an example of CDOSYS:-

http://forums.webwiz.net/sending-email-with-cdosys_topic28749_post144837.html#144837

If you are not able to update your code correctly from the above example, start a support ticket from your Client Area account and we will have a quick look for you to see if can find where you have the incorrect code.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.07
Copyright ©2001-2024 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Policy

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2024 Web Wiz Ltd. All rights reserved.