473,545 Members | 2,004 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Trouble in sending emails using CDO

Hi,

I am using CDO component to send emails through my ASP page as I am
having IIS on windows XP..........
Now the mails goes and gets into mailroot\Queue folder but does not
reaches to the destination.... ....
Pls tell me what do I need to do.........

here goes my code for your reference.....

Const cdoSendUsingPic kup = 1
Const cdoSendUsingPor t = 2
Const cdoSendUsingExc hange = 3

Const cdoAnonymous = 0
Const cdoBasic = 1
Const cdoNTLM = 2

'Sends an email To aTo email address, with Subject And TextBody.
'The email is In text format.
'Lets you specify BCC adresses, Attachments, smtp server And Sender
email address
Function SendMailByCDO(a To, Subject, TextBody, smtp, aFrom )
on error resume Next

Dim Message 'As New CDO.Message '(New - For VBA)

'Create CDO message object
Set Message = CreateObject("C DO.Message")

'Set configuration fields.
With Message.Configu ration.Fields 'Original sender email address

..Item("http://schemas.microso ft.com/cdo/configuration/sendemailaddres s")
= aFrom

' SMTP settings - without authentication, using standard port 25 on
host smtp
.Item("http://schemas.microso ft.com/cdo/configuration/sendusing ")
= cdoSendUsingPor t

..Item("http://schemas.microso ft.com/cdo/configuration/smtpserverport" )
= 25
.Item(" http://schemas.microso ft.com/cdo/configuration/smtpserver")
= smtp

'SMTP Authentication

..Item("http://schemas.microso ft.com/cdo/configuration/smtpauthenticat e
") = cdoAnonymous

.Update
End With

'Set other message fields.
With Message
'From, To, Subject And Body are required.
.From = aFrom
.To = aTo
.Subject = Subject

'Set TextBody property If you want To send the email As plain text
.HTMLBody = TextBody

'Set HTMLBody property If you want To send the email As an HTML
formatted
'.HTMLBody = TextBody

'Blind copy And attachments are optional.
If Len(BCC)>0 Then .BCC = BCC
If Len(Files)>0 Then .AddAttachment Files

'Send the email
.Send
End With

'Returns zero If succesfull. Error code otherwise
SendMailByCDO = Err.Number
End Function

Function SendMail()
Const smtp = "20.139.68. 2"
Const aFrom = "ma**@mail. com"
aTo="ar******** *@gmail.com"
Subject="Foo"
TextBody="fsdfs dfsd"

call SendMailByCDO(a To, Subject, TextBody, smtp, aFrom )
End Function

call SendMail()

Regards,
Amit Arora

May 18 '06 #1
4 3737
On 18 May 2006 08:20:28 -0700, ar*********@gma il.com wrote:
Hi,

I am using CDO component to send emails through my ASP page as I am
having IIS on windows XP..........
Now the mails goes and gets into mailroot\Queue folder but does not
reaches to the destination.... ....


Start with:

http://www.aspfaq.com/show.asp?id=2268

Jeff
May 19 '06 #2
Well Buddy,
This link jumped me to problem shotting for Windows 2000, though I
tested it on my windows XP server and found the same result i.e getting
into Queue folder....

Thanks
Amit Arora

Jeff Cochran wrote:
On 18 May 2006 08:20:28 -0700, ar*********@gma il.com wrote:
Hi,

I am using CDO component to send emails through my ASP page as I am
having IIS on windows XP..........
Now the mails goes and gets into mailroot\Queue folder but does not
reaches to the destination.... ....


Start with:

http://www.aspfaq.com/show.asp?id=2268

Jeff


May 19 '06 #3
On 18 May 2006 22:09:51 -0700, ar*********@gma il.com wrote:
Well Buddy,
This link jumped me to problem shotting for Windows 2000, though I
tested it on my windows XP server and found the same result i.e getting
into Queue folder....
So, did you fix the problem? Did you look at the logs? Does anything
get delivered? Is your DNS correct? Have you tested the SMTP
manually? Checked the firewall?

Jeff

Thanks
Amit Arora

Jeff Cochran wrote:
On 18 May 2006 08:20:28 -0700, ar*********@gma il.com wrote:
>Hi,
>
>I am using CDO component to send emails through my ASP page as I am
>having IIS on windows XP..........
>Now the mails goes and gets into mailroot\Queue folder but does not
>reaches to the destination.... ....


Start with:

http://www.aspfaq.com/show.asp?id=2268

Jeff


May 20 '06 #4

Jeff Cochran wrote:
On 18 May 2006 22:09:51 -0700, ar*********@gma il.com wrote:
Well Buddy,
This link jumped me to problem shotting for Windows 2000, though I
tested it on my windows XP server and found the same result i.e getting
into Queue folder....


So, did you fix the problem? Did you look at the logs? Does anything
get delivered? Is your DNS correct? Have you tested the SMTP
manually? Checked the firewall?

Jeff

Thanks
Amit Arora

Jeff Cochran wrote:
On 18 May 2006 08:20:28 -0700, ar*********@gma il.com wrote:

>Hi,
>
>I am using CDO component to send emails through my ASP page as I am
>having IIS on windows XP..........
>Now the mails goes and gets into mailroot\Queue folder but does not
>reaches to the destination.... ....

Start with:

http://www.aspfaq.com/show.asp?id=2268

Jeff

I dunno but you're using 'anonymous' authentication (i.e. no
authentication) , maybe the server is not processing them because of
that? Change it to basic and supply a username/password to
authenticate (a valid username/password defined in the email server),
which also should be the same one in the 'from' field to reduce
potential problems (like relaying forbidden and stuff)

May 22 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
4946
by: Stuart Mueller | last post by:
I have an exchange server, that I sometimes use to perform mail shots to clients on our database, these can be upwards of 1000 at a time. As we don't want different clients to see who we are working with we put these mailshots in the bcc field of the mails. This can sometimes cause a problem as we are getting alot of mails bounced back. I...
1
5122
by: Ian Taylor | last post by:
Hi all... Is it possible to send RTF-formatted emails using the .NET SmtpMail implementation? I can only find provision in the BodyFormat property of the message to send plain text or HTML emails. I also have a similar problem in sending HTML/RTF emails via MAPI and would appreciate any help anyone could give me in these areas.
3
2214
by: VB Programmer | last post by:
My company has it's own webserver, which is going to host our ASP.NET web application. We want the website to be able to send out emails. 1. What do I need on the server so that it has the abillity to send out emails? It is a Windows 2000 Professional SP3 server. 2. Any examples (code, etc...) on how to send out emails via an ASP.NET...
2
9211
by: Mr. x | last post by:
Hello, I am sending emails with Hebrew contents. When receiving emails - I cannot see the Hebrew characters (it is not outlook express configuration, because when receiving emails from friends - I see hebrew, it is just sending by myself using *.aspx scripts). In web.config I have the following : <configuration> <system.web>
3
1583
by: A | last post by:
Hi all! I would like to ask a question on sending emails... I have a web application that requires sending emails using email templates. The templates that I've made are separate HTML files and would require some data based on what the user has entered. Please help!!!
3
3599
by: Ant | last post by:
Hi, I'm using the MailMessage & smtpMail classes in System.Web.Mail to send mail, however it's not sending any emails. I'm using it on a Windows 2003 server. The simplest way to use this is smtpMail.Send("from@here.com", to@there.com, "Message subject", "Message Body") I'm sending it to my own email address on a different server using...
5
2429
by: Jai | last post by:
Hi, I am in a problem of sending mass emails(newsletter) to my website members. Actually my problem is this: I want to send newsletter to my website members. But I had given a facility for each member to choose different category of products or all products newsletter.
27
1987
by: stonemcstone | last post by:
I've been programming in C for years, and never experienced troubles until I started using the new RealC-32, a freeware C compiler from the same company that makes RealPlayer and Quicktime. That's when the trouble started. See, RealC-32 is like any other C compiler but with one notable difference. Any time your code invokes undefined...
0
1763
by: damimkader | last post by:
Hi, I'm trying to send emails using a Macro based on an Excel Sheet and the Email Client I'm using is Lotus Notes. OS used - Windows Xp. Language - VB Below is the Code I'm using for doing the same. Dim Maildb As Object
0
7675
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
7928
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7440
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7775
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5997
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
3470
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
1902
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1030
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
726
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.