I am trying to send email using rcpt to. I had set from address(firstname.lastname@example.org) but at the receiver and it show actual email address (email@example.com). Can you please help me to solve this problem? Here is my code.
Smtp smtp = new Smtp();
smtp.Login("firstname.lastname@example.org", password, SmtpAuthentication.Login);
string mailFrom = "email@example.com";
string rcptTo = "rcptTo@domain.com";
string mailTo = "firstname.lastname@example.org";
MailMessage mail = new MailMessage();
mail.To = mailTo;
mail.From = mailFrom;
mail.Subject = "Hello Freddy, this is your friend Peter sending you a test email";
mail.BodyText = "Hello Freddy, this is the body text";
smtp.Send(mail, mailFrom, rcptTo);
I tried with sample that I got from the website. But I still got same error. It behave same for both Send method.