Solved

SMTP Mailing Problem

Posted on 2011-09-08
1
473 Views
Last Modified: 2012-05-12
I have personal domain in google and now i have created my id as

donotreply@TDIforAccess.org

Now i tried to send my mail through SMTP server, below is my code
------------------------------------------------------------------------------
 Dim emailMessage As MailMessage
        emailMessage = New MailMessage
        emailMessage.From ="donotreply@TDIforAccess.org"
        emailMessage.To = "donotreply@TDIforAccess.org"
        emailMessage.Subject = "Thanks"
        emailMessage.Body = "Testing"  
        emailMessage.BodyFormat = MailFormat.Html
        SmtpMail.SmtpServer = "localhost"

        Try            
            SmtpMail.Send(emailMessage)          
        Catch ex As Exception
            Respone.Write(ex.Tostring)
        End Try
------------------------------------------------------------------------------------------------------

I got this error

System.Web.HttpException (0x80004005): The server rejected one or more recipient addresses. The server response was: 550 Requested action not taken: mailbox unavailable or not local ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException: The server rejected one or more recipient addresses. The server response was: 550 Requested action not taken: mailbox unavailable or not local --- End of inner exception stack trace --- at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams) at System.Web.Mail.SmtpMail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) at System.Web.Mail.SmtpMail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) at System.Web.Mail.SmtpMail.CdoSysHelper.Send(MailMessage message) at System.Web.Mail.SmtpMail.Send(MailMessage message) at temp.btnsubmit_Click(Object sender, EventArgs e) in

----------------------------------------------------------------------------------------------------

Please give me solutions
0
Comment
Question by:citadelind
[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
1 Comment
 
LVL 25

Accepted Solution

by:
Rouchie earned 500 total points
ID: 36501152
After this:

SmtpMail.SmtpServer = "localhost"

Try adding:

SmtpMail.DeliveryMethod = SmtpDeliveryMethod.PickupDirectoryFromIis
0

Featured Post

Quiz: What Do These Organizations Have In Common?

Hint: Their teams ended up taking quizzes, too.

Question has a verified solution.

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

Color can increase conversions, create feelings of warmth or even incite people to get behind a cause. If you want your website to really impact site visitors, then it is vital to consider the impact color has on them.
This article was originally published on Monitis Blog, you can check it here . Today it’s fairly well known that high-performing websites and applications bring in more visitors, higher SEO, and ultimately more sales. By the same token, downtime…
The basic steps you have just learned will be implemented in this video. The basic steps are shown to configure an Exchange DAG in a live working Exchange Server Environment and manage the same (Exchange Server 2010 Software is used in a Windows Ser…
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.

691 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