客户网站中的异常错误

时间:2013-08-27 03:52:37

标签: c# asp.net .net razor

我刚在客户的网站上创建了一个帐户(我为他建立了这个帐户)。我已经对这个网站进行了广泛的测试,并且在2年前找不到任何问题。我已经对它进行了测试,以确保自网站发布以来每个月都能顺利运行。

我刚刚在他的网站上创建了一个新帐户,我收到了这个错误:

Server Error in '/' Application.

Mailbox unavailable. The server response was: <me@myemail.com> No such user here 
  Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

 Exception Details: System.Net.Mail.SmtpFailedRecipientException: Mailbox unavailable. The server response was: <me@myemail.com> No such user here

Source Error: 



Line 62:                         HttpUtility.UrlEncode(token));
Line 63: 
Line 64:                     WebMail.Send(
Line 65:                         email,
Line 66:                         "Please confirm your Account.",


 Source File:  d:\HostingSpaces\website\website.com.au\wwwroot\Protected\Account\Register.cshtml    Line:  64 

Stack Trace: 



[SmtpFailedRecipientException: Mailbox unavailable. The server response was: <me@myemail.com> No such user here]
   System.Net.Mail.SmtpTransport.SendMail(MailAddress sender, MailAddressCollection recipients, String deliveryNotify, SmtpFailedRecipientException& exception) +1229659
   System.Net.Mail.SmtpClient.Send(MailMessage message) +1772
   System.Web.Helpers.WebMail.Send(String to, String subject, String body, String from, String cc, IEnumerable`1 filesToAttach, Boolean isBodyHtml, IEnumerable`1 additionalHeaders, String bcc, String contentEncoding, String headerEncoding, String priority, String replyTo) +686
   ASP._Page_Protected_Account_Register_cshtml.Execute() in d:\HostingSpaces\website\website.com.au\wwwroot\Protected\Account\Register.cshtml:64
   System.Web.WebPages.WebPageBase.ExecutePageHierarchy() +208
   System.Web.WebPages.WebPage.ExecutePageHierarchy(IEnumerable`1 executors) +68
   System.Web.WebPages.WebPage.ExecutePageHierarchy() +123
   System.Web.WebPages.StartPage.RunPage() +19
   System.Web.WebPages.StartPage.ExecutePageHierarchy() +67
   System.Web.WebPages.WebPageBase.ExecutePageHierarchy(WebPageContext pageContext, TextWriter writer, WebPageRenderingBase startPage) +78
   System.Web.WebPages.WebPageHttpHandler.ProcessRequestInternal(HttpContextBase httpContext) +121




Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.272 

什么???下面列出的电子邮件地址是我用来创建帐户的电子邮件地址。收到此错误后,我在线登录该电子邮件帐户 - 它就在那里 - 包含我的所有邮件。所以用户确实存在。那么为什么WebPages框架在尝试向其发送电子邮件确认时该用户不存在呢?

您在代码中看到的电子邮件变量 - 它的值列​​在异常本身中。

1 个答案:

答案 0 :(得分:0)

由于某些原因,邮件可能会在几分之一秒内无法使用。再次尝试创建帐户,它应该没问题。