CDO.Message

S

Steve

Hi all,

I'm trying to send e-mail using ASP: "CDO.Message" but
its not working for me.

I'm trying to use SMTP within IIS to send the mail (not
our exchange server), the "Default SMTP Virtual Server"
is started and running. The "Simple Mail Transfer
Protocol (SMTP)" service within 'Services' is started and
running. My machine is Win XP Pro.

This is my code (from devguru.com):

<%
Dim MyMail
Set MyMail = Server.CreateObject("CDO.Message")
MyMail.From = "(e-mail address removed)"
MyMail.To = "(e-mail address removed)"
MyMail.Cc = ""
MyMail.Bcc = ""
MyMail.Subject = "Subject"
MyMail.TextBody = "Text Body"
MyMail.Fields.Update()
MyMail.Send()
Set MyMail = Nothing
%>

This is the error:

CDO.Message.1 (0x80040220)
The "SendUsing" configuration value is invalid.
/NewOnlineForms/test3.asp, line 14

I was using "CDONTS.NewMail" but I was advised to try and
move to "CDO.Message".

Any help with this would be great.

Thanks,

Steve
 
S

Steve

Thanks for this, but I'm not sure that's my problem, I
haven't installed any version of Exchange on this
machine. The Exchange I mentioned is our exchange server
on our network, but I'm trying to use the SMTP service
within IIS to send the mail.

Thanks anyway.

Steve
 
A

Aaron Bertrand - MVP

You can't just change CDONTS code to CDO.Message by swapping out the ProgID.
See the sample cdo.message code here:

http://www.aspfaq.com/2026

For other samples, search for "cdo.message" without the quotes.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,969
Messages
2,570,161
Members
46,710
Latest member
bernietqt

Latest Threads

Top