By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,953 Members | 1,143 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,953 IT Pros & Developers. It's quick & easy.

problem with sending email from VBA using CDO for Windows 2000

P: n/a
I am using CDO for Windows 2000 to send emails. There is a method
..Send() of CDO.Message object, I call this method and usualy
averything is fine. But how can I be sure that the message was
successfully sent? If SMTP server is not accessible, for example,
there are no error messages, no exceptions, everything goes smoothly,
except for the fact, that no messages are sent out.

Does .Send() method return some error values?

This is extract from my code:

Set cdoConfig = CreateObject("CDO.Configuration")
With cdoConfig.Fields
.Item(cdoSendUsingMethod) = cdoSendUsingPort
.Item(cdoSMTPServerPort) = myPort
.Item(cdoSMTPServer) = "myServer"
.Item(cdoSendUserName) = "myName"
.Item(cdoSendPassword) = "myPassword"
End With

Set Msg = CreateObject("CDO.Message")

Set Msg.Configuration = cdoConfig
Msg.To = te**
Msg.From = my*******
Msg.Subject = "Test subject"
Msg.TextBody = "Body of test message"

Nov 12 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.