Help | Site Map
Connecting Tech Pros Worldwide
 
 
LinkBack Thread Tools
  #1  
Old July 19th, 2005, 01:07 PM
dave
Guest
 
Posts: n/a
Default sending email using CDO Message

Hi There
I have got little bit asp code to send email
It was working if its hosted on windows 2000..

But it doesnt work on winows server 2003..I guess it
might be problem with specifying schema..I'm using CDO
Message object. Below is the code tht i m using...

sch = "http://schemas.microsoft.com/cdo/configuration/"
Set cdoConfig = Server.CreateObject("CDO.Configuration")
With cdoConfig.Fields
.Item(sch & "sendusing") = 2 ' cdoSendUsingPort
.Item(sch & "smtpserver") = "mail.neospace.net.au"
.update
End With
Set cdoMessage = Server.CreateObject("CDO.Message")
With cdoMessage
Set .Configuration = cdoConfig
.From = "test@mydomain.com"
.To = "abc@xyz.com.au"
.Subject = "subject"
.HtmLBody = "message body"
.Send
End With
Set cdoMessage = Nothing
Set cdoConfig = Nothing

Do i need to authorised and log in SMTP server using From
id or its has different configuration problem ?
Any suggestion would be appreciated
Thanx
dave

  #2  
Old July 19th, 2005, 01:08 PM
Aaron Bertrand - MVP
Guest
 
Posts: n/a
Default Re: sending email using CDO Message

What does "doesn't work" mean?

--
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/




"dave" <anonymous@discussions.microsoft.com> wrote in message
news:87ab01c43267$661d6800$a101280a@phx.gbl...[color=blue]
> Hi There
> I have got little bit asp code to send email
> It was working if its hosted on windows 2000..
>
> But it doesnt work on winows server 2003..I guess it
> might be problem with specifying schema..I'm using CDO
> Message object. Below is the code tht i m using...
>
> sch = "http://schemas.microsoft.com/cdo/configuration/"
> Set cdoConfig = Server.CreateObject("CDO.Configuration")
> With cdoConfig.Fields
> .Item(sch & "sendusing") = 2 ' cdoSendUsingPort
> .Item(sch & "smtpserver") = "mail.neospace.net.au"
> .update
> End With
> Set cdoMessage = Server.CreateObject("CDO.Message")
> With cdoMessage
> Set .Configuration = cdoConfig
> .From = "test@mydomain.com"
> .To = "abc@xyz.com.au"
> .Subject = "subject"
> .HtmLBody = "message body"
> .Send
> End With
> Set cdoMessage = Nothing
> Set cdoConfig = Nothing
>
> Do i need to authorised and log in SMTP server using From
> id or its has different configuration problem ?
> Any suggestion would be appreciated
> Thanx
> dave
>[/color]


 

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over network members.
Post your question now . . .
It's fast and it's free

Popular Articles