locked
URGENT Help needed in EMAIL issues.. RRS feed

  • Question

  • User1368713674 posted

    Hi,

    I am facing the email issue. If the email is sent from the same domain email address then the email is sent sucessfully. (example) my domain name is www.DubaiOnlineClassifieds.com. If some one sends email to admin@dubaionlineclassifieds.com from contact us form then the email is delievered sucessfully.

    If i am sending emails from the site to some other email address like admin@yahoo.com then the email is not delivered. BECAUSE OF THIS I COULD NOT USE THE "FORWARD IT TO FRIEND", "PASSWORD RECOVERY"...functionalities.

     If some has faced similar issues please respond to this post and help me out to fix the issue.

    Already I have used the username and password in the config file. i tried using the IP of the SMTP server...

    HELP ME TO SORT THIS ISSUE.

    Regards,
    Richard I.P

    Monday, March 30, 2009 12:30 PM

All replies

  • User-1659704165 posted

    Hi,

    To send mail from Yahoo Or Mail
    provide U have Authenticate
    Below Code Help U Authenticate From Foregin Adress

    bool mailSent = false;
                MailMessage mail = new MailMessage();
                try
                {
                    mail.To = toID;
                    mail.From = fromID;
                    mail.Subject = subject;
                    mail.Body = body;
                    mail.BodyFormat = MailFormat.Html;
                    mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate", "1");
                    mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendusername", "<Your Yahoo id>");
                    mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendpassword", "<Your Yahoo password>);
                    SmtpMail.SmtpServer = "<SMPT Address Of Yahoo>";
                    SmtpMail.Send(mail);
                    mailSent = true;
                }
                catch
                {
                    mailSent = false;
                }

    Hope It Helps

     

    Tuesday, March 31, 2009 2:34 AM
  • User730446648 posted

    Easy fix.

    See my post here.
    http://forums.asp.net/t/1324582.aspx

    Friday, April 3, 2009 12:45 AM