Solved

CDO Error message

Posted on 2003-11-12
9
1,092 Views
Last Modified: 2007-12-19
Hello I am getting an error message

error '8004020e'
/index.asp, line 397

Line 397 is the Send method in the following code
<%
Dim iMsg
Dim iConf
Dim Flds
Dim strHTML
                      
set iMsg = CreateObject("CDO.Message")
set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
                      
With Flds
 .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
 .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "mail.mgdinc.com"
 .Item("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 40
 .Update
End With
                  
With iMsg
 Set .Configuration = iConf
      .From              = emailFrom
      .To              = emailTo
      .Subject             = emailSubject
      .HTMLBody       = "Email Text"
      .TextBody             = .HTMLBody
      .Send                                                      'error here
End With
                          
Set iMsg = Nothing
Set iConf = Nothing
Set Flds = Nothing
%>

 The error is most likely caused by somthing not being setup up or configured correctly. The same code works on another website on the same server. I can not find any differences between the sites except that Exchange is somehow set up on the other one. I should explain that the previous example used to have a conflict with Exchange, that required me to reinstall it, something that I would like to avoid this time.
Thanks for your help
ff
0
Comment
Question by:funkyfinger
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
9 Comments
 
LVL 46

Expert Comment

by:fritz_the_blank
ID: 9734671
Is this a valid and properly configured smtp server?

mail.mgdinc.com

FtB
0
 
LVL 2

Author Comment

by:funkyfinger
ID: 9734978
Yes, it works fine on another website on the same server.
Under "Internet services manager" I have 2 sites listed the old and the new one. SMTP is not listed here, I'm not sure if it should be, if I expand the old site one subheading is called "Exchange", I don't know if that information helps you or not.
Thanks
ff
0
 
LVL 3

Expert Comment

by:barryfandango
ID: 9734980
This guy had the same problem:

http://www.mail-archive.com/asp_cdo@p2p.wrox.com/msg01360.html

Maybe one of the solutions suggested here will work for you.
0
Salesforce Made Easy to Use

On-screen guidance at the moment of need enables you & your employees to focus on the core, you can now boost your adoption rates swiftly and simply with one easy tool.

 
LVL 2

Author Comment

by:funkyfinger
ID: 9735593
Thanks for your help guys, I've decided to give up on the problem and go with CDONTS,
btw That doesn't work on the web site with exchange.
ff
0
 
LVL 46

Expert Comment

by:fritz_the_blank
ID: 9735789
I would recommend looking into the free and excellent ASPeMail from www.Persits.com .

It works well with remote smtp services and is easy to work with.

FtB
0
 
LVL 46

Expert Comment

by:fritz_the_blank
ID: 9736037
It is an irregular request given the options that were listed above. If funkyfinger truly believes that s/he received no help here whatsoever, then I suppose that it is alright to process the refund.

FtB
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 9754188
PAQed, with points refunded (250)

Computer101
E-E Admin
0
 
LVL 46

Expert Comment

by:fritz_the_blank
ID: 9754244
FunkyFinger--

Please maintain your open questions:

Questions Asked 29
Questions Open 8
Questions Graded: 19
Questions Deleted: 2
Last 10 Grades Given: A A A A A A A A A B

Fritz the Blank
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question