Dear all, I have used PasswordRecovery control on my web site; it works for user who has an e-mail on the same domain of my website but when the user's e-mail belongs to another domain such as hotmail.com or gmail.com, I get an error message (so it works but not for the e-mails on the other domains!) Exception Details: System.Net.Mail.SmtpFailedRecipientException: Mailbox unavailable. The server response was: <[email protected]> No such user here Stack Trace: [SmtpFailedRecipientException: Mailbox unavailable. The server response was: <[email protected]> No such user here] System.Net.Mail.SmtpTransport.SendMail(MailAddress sender, MailAddressCollection recipients, String deliveryNotify, SmtpFailedRecipientException& exception) +1078355 System.Net.Mail.SmtpClient.Send(MailMessage message) +1480 System.Web.UI.WebControls.LoginUtil.SendPasswordMail(String email, String userName, String password, MailDefinition mailDefinition, String defaultSubject, String defaultBody, OnSendingMailDelegate onSendingMailDelegate, OnSendMailErrorDelegate onSendMailErrorDelegate, Control owner) +367 System.Web.UI.WebControls.PasswordRecovery.AttemptSendPasswordQuestionView() +522 System.Web.UI.WebControls.PasswordRecovery.AttemptSendPassword() +69 System.Web.UI.WebControls.PasswordRecovery.OnBubbleEvent(Object source, EventArgs e) +103 System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +37 System.Web.UI.WebControls.Button.OnCommand(CommandEventArgs e) +118 System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +166 System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10 System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13 System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565 Version Information: Microsoft .NET Framework Version:2.0.50727.4016; ASP.NET Version:2.0.50727.4016 Would you please help me to find the problem? Best regards, Faramarz
I have modified the config file but still the same problem Hi. I have modified the config file as follows: <system.net> <mailSettings> <smtp from="[email protected]"> <network host="localhost" /> </smtp> </mailSettings> </system.net> But still the same problem?! Please help me to find the problem, Thank you all!
...Where is the hotmail? On a Contact page? This is the settings I'm using, successfully, for both a Contact page and Health Monitoring. <system.net> <mailSettings> <smtp from="[email protected]" deliveryMethod="Network"> <network host="localhost" port="25" password="mypasssword" userName="[email protected]" /> </smtp> </mailSettings> </system.net>
I have already used the code but it hasn't worked! Hi. Thanks a lot for your response. I have already used the above localhost code but I got the following error: Would you please have a look at it and help me to find the problem? Thank you very much in advance, Faramarz Server Error in '/Dr. Hesami Web Site' Application. No connection could be made because the target machine actively refused it ::1:25 [FONT=Arial, Helvetica, Geneva, SunSans-Regular, sans-serif] 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.Sockets.SocketException: No connection could be made because the target machine actively refused it ::1:25 Source Error: An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace: [SocketException (0x274d): No connection could be made because the target machine actively refused it ::1:25] System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress) +239 System.Net.Sockets.Socket.InternalConnect(EndPoint remoteEP) +35 System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Int32 timeout, Exception& exception) +224 [WebException: Unable to connect to the remote server] System.Net.ServicePoint.GetConnection(PooledStream PooledStream, Object owner, Boolean async, IPAddress& address, Socket& abortSocket, Socket& abortSocket6, Int32 timeout) +5421675 System.Net.PooledStream.Activate(Object owningObject, Boolean async, Int32 timeout, GeneralAsyncDelegate asyncCallback) +202 System.Net.PooledStream.Activate(Object owningObject, GeneralAsyncDelegate asyncCallback) +21 System.Net.ConnectionPool.GetConnection(Object owningObject, GeneralAsyncDelegate asyncCallback, Int32 creationTimeout) +332 System.Net.Mail.SmtpConnection.GetConnection(String host, Int32 port) +160 System.Net.Mail.SmtpTransport.GetConnection(String host, Int32 port) +159 System.Net.Mail.SmtpClient.GetConnection() +35 System.Net.Mail.SmtpClient.Send(MailMessage message) +1213 [SmtpException: Failure sending mail.] System.Net.Mail.SmtpClient.Send(MailMessage message) +1531 System.Web.UI.WebControls.LoginUtil.SendPasswordMail(String email, String userName, String password, MailDefinition mailDefinition, String defaultSubject, String defaultBody, OnSendingMailDelegate onSendingMailDelegate, OnSendMailErrorDelegate onSendMailErrorDelegate, Control owner) +367 System.Web.UI.WebControls.PasswordRecovery.AttemptSendPasswordQuestionView() +522 System.Web.UI.WebControls.PasswordRecovery.AttemptSendPassword() +69 System.Web.UI.WebControls.PasswordRecovery.OnBubbleEvent(Object source, EventArgs e) +103 System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +37 System.Web.UI.WebControls.Button.OnCommand(CommandEventArgs e) +118 System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +166 System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10 System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13 System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565 Version Information: Microsoft .NET Framework Version:2.0.50727.4016; ASP.NET Version:2.0.50727.4016 [/FONT]
Thanks a lot Thanks a lot. They have fixed the problem. Now it works but the process was really time consuming and frustrating. Thank you all.
Don't know I don't know but without changing any code now it's working; may be something was wrong with the servers.