From address problem in Sending Mail
-
Hi all, I am trying send mail. I added email settings to web.config The problem is when i am sending mail, mail delivers. But with from address admin@mydomain.com [userName] but not 'donotreply@mydomain.com' any solution. To change the from address [avoiding UserName as From address]. Regards, sekhar
-
Hi all, I am trying send mail. I added email settings to web.config The problem is when i am sending mail, mail delivers. But with from address admin@mydomain.com [userName] but not 'donotreply@mydomain.com' any solution. To change the from address [avoiding UserName as From address]. Regards, sekhar
sekhar.k wrote:
Does this mail address exist ?
-
sekhar.k wrote:
Does this mail address exist ?
Hi Abijit. Thanks for ur response. donotreply@[mydomainhere].com is exist, but in-place of 'mydomain' we have our domain name. The mail actually delivers to given to address. But there it showing from address as 'admin@mydomain.com' which is username used in web.config mailSettings. But i need from address as 'donotreply@[mydomainhere].com'. any suggestions. regards, kv sekhar
-
Hi Abijit. Thanks for ur response. donotreply@[mydomainhere].com is exist, but in-place of 'mydomain' we have our domain name. The mail actually delivers to given to address. But there it showing from address as 'admin@mydomain.com' which is username used in web.config mailSettings. But i need from address as 'donotreply@[mydomainhere].com'. any suggestions. regards, kv sekhar
Ok, you can set the
Name
for mail address. That will display whatever name you provide with the adderess.MailAddress from = new MailAddress("admin@mydomain.com", "donotreply@[mydomainhere].com");
-
Ok, you can set the
Name
for mail address. That will display whatever name you provide with the adderess.MailAddress from = new MailAddress("admin@mydomain.com", "donotreply@[mydomainhere].com");
Hi Abijit, I tried your logic by sending a sample email to my email address[gamil]. But no use. The display name appears in 'from' but it also shows the 'userName' when we click on 'show deails' link. When i open my mail from inbox. It displays the from as 'donotreply@[mydomainhere].com'. But when i click on 'show details' link it displays like below. "donotreply@[mydomainhere].com" I don't want show 'UserName' in Recipient user. Because its a credential. Any solution? Regards, kv sekhar