Solved

Problem using CDO  in VB.NET

Posted on 2004-08-03
4
648 Views
Last Modified: 2011-10-03
Hi all,

Iam using CDO with VB.net to send user Login information(username and Password).

Iam using the following code to send the e-mail.


 Dim objMsg As New CDO.Message()
             Dim conf As New CDO.Configuration()
           Const cdoSendUsingPort = 2
            Dim Flds = conf.Fields

            With Flds
             .item("http://schemas.microsoft.com/cdo/configuration/sendusing") = cdoSendUsingPort
            .item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "MailServer"
            .item("http://schemas.microsoft.com/cdo/configuration/smtpauthencation") = 0
            .item("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 15
            .item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
            .update()
            End With

            Flds("urn:schemas:httpmail:importance").value = 2

             With objMsg
             .Configuration = conf
            .From = "me@xxx.com"
             .To = "you@xx.com"
            .Subject = "Web Timecard Login information"
            .HTMLBody = " Here is the HTML body text message"
            .Send()
            End With

            objMsg = Nothing
            conf = Nothing
            Flds = Nothing
  When I first run the program, it was sent the mail sucessfully. It tool around 15 to 20 Minutes to receive the e-mail. Then i have tested several times. Later i didn't get any mail. But i can see the application run successfully.
I got one error message, saying that.

    Error Message: Your E-mail message was unable to send because your mail server rejects the sender. 451 timeout waiting for client input.



Do i need to setup something in the mail server to accept SMTP mail messages?. we are using Outlook e-mails.


Can anyone please tell me how can I solve this issue.


Thanks in advance..

Regards,
Raju.
0
Comment
Question by:kbraju76
[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
  • 2
4 Comments
 
LVL 10

Expert Comment

by:Clif
ID: 11706465
Just a thought...

Some mail servers have a mass mailing filter which prevents muliple identical emails from being sent through.  I was having a similar problem myself, until I changes my test email slightly for each test.
0
 
LVL 8

Expert Comment

by:rfgkev
ID: 11706571
/agree with Clif

Also, is the Sender address a 'Real' address? it could be that the mail server is trying to do a reverse DNS lookup on the sender address and not finding it. Doesn't sound like this as it sent the first time thou, unless you changed the sender address ofcourse :)

Try setting up the SMTP service on your machine and sending them through that.
0
 
LVL 17

Expert Comment

by:AerosSaga
ID: 11707276
0
 
LVL 17

Accepted Solution

by:
AerosSaga earned 500 total points
ID: 11707314
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

This tutorial demonstrates one way to create an application that runs without any Forms but still has a GUI presence via an Icon in the System Tray. The magic lies in Inheriting from the ApplicationContext Class and passing that to Application.Ru…
A while ago, I was working on a Windows Forms application and I needed a special label control with reflection (glass) effect to show some titles in a stylish way. I've always enjoyed working with graphics, but it's never too clever to re-invent …
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

734 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