SmtpMail.Send() No Error but no Email either.

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Hi,

I use the standard code given below to send an email from an ASP.NET
web form. The code executes fine but no Email is sent. All emails get
queued in the Inetpub mail queue.

I'm using my local default SMTP Server and my from address is a valid
Yahoo/Hotmail address. I have configures the local SMTP Server to allow
the IP Address 127.0.0.1.

Could this be because yahoo/hotmail servers need authentication?

Here's the code I use.

private void SendSimpleMail()
{

MailMessage objEmail = New MailMessage();
objEmail.From = "valid_id@xxxxxxxxx";
objEmail.To = "another_valid_id@xxxxxxxxxxx";
objEmail.Subject = "Test Mail";
objEmail.Body = "Test Mail - Body";
SmtpMail.SmtpServer = "127.0.0.1";


SmtpMail.Send(objEmail);

}


Any idea what could be wrong or what I need to do to send a simple
email from ASP.NET? Any help would be appreaciated.

Regards,
supz

.



Relevant Pages

  • Re: SmtpMail.Send() No Error but no Email either.
    ... gmail is the example I use....you might want to get an gmail account and use ... I'm using my local default SMTP Server and my from address is a valid ... I have configures the local SMTP Server to allow ... Could this be because yahoo/hotmail servers need authentication? ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: SmtpMail.Send() No Error but no Email either.
    ... If you get the yahoo settings worked out...with my code from my blog. ... I'm using my local default SMTP Server and my from address is a valid ... I have configures the local SMTP Server to allow ... Could this be because yahoo/hotmail servers need authentication? ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: SMTP behind NAT
    ... You are therefore forced to send mail via a local smtp server. ... Learn all of the latest penetration testing techniques in InfoSec Institute's Ethical Hacking class. ... Totally hands-on course with evening Capture The Flag exercises, Certified Ethical Hacker and Certified Penetration Tester exams, taught by an expert with years of real pen testing experience. ...
    (Security-Basics)
  • Re: Mail sending problems
    ... but it is one to bear in mind when your email fails to arrive. ... gone through, but as of a few years ago, the SMTP server avalable to BT ... Openworld business ADSL accounts very definitely did only allow From ... We had to set up a local SMTP server ...
    (comp.sys.acorn.networking)
  • Re: Sending mail between 2 lan computers
    ... It uses the local SMTP server, ... > "Kristofer Gafvert" wrote in message ... >> G Dean Blake wrote: ...
    (microsoft.public.inetserver.iis)