This is my code.
try
{
MailMessage message = new MailMessage("amila_4u@yahoo.com", "shashika_4u@yahoo.com", "Hello", "This is a test");
SmtpClient emailClient = new SmtpClient("localhost");
emailClient.Send(message);
Suc_txt.Text = "Message Sent";
}
catch (Exception ex)
{
Suc_txt.Text = ex.ToString();
}
This is the exception message i get when i click the button in aspx web page.
System.Net.Mail.SmtpFailedRecipientException: Mailbox name not allowed. The server response was: We do not relay non-local mail, sorry.
Please reply anyone who knows about this problem quickly, as i'm in a hurry to finish the web site. i use the windows xp smtp server.
Kalpa [ shashika_4u ( at ) yahoo dot com ],
2006-05-02 03:38:29
#