C# .NET - exclude "From" attribute in the header of an email

Asked By Sudhansu shekhar on 20-May-13 02:55 AM
Hello everyone, Good afternoon.

I have an urgent issue, I want exclude "From" attribute in the header of an email when i send to someone. I want to use our own "from" email address and just have a text box where if we enter new value or Email id, instead of actual "From" so this has to be display to the sent person email.

Thanks.
Robbe Morris replied to Sudhansu shekhar on 20-May-13 12:38 PM
Are you using your SMTP server and standard POP 3 access or are you using windows authentication and sending the mail from Microsoft Exchange?
Sudhansu shekhar replied to Robbe Morris on 21-May-13 02:47 AM
Thanks for your reply Robbe,
Yes Im using SMTP server with window authentication, What is the solution I can have. please let me know, its an urgent. Thanks once again.
Robbe Morris replied to Sudhansu shekhar on 21-May-13 07:12 AM
You are going to need to use a valid/existing "from" or many mail servers will assume you are spam and stop accepting your emails from that SMTP server.  You can use a "from" you want by specifying it in your code.  But, again, if you don't want problems with other mail servers, you'll use a valid email address as the from.