Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

sending email with arabic content

Status
Not open for further replies.

camy123

Programmer
Mar 5, 2004
171
GB
hi can some please help me urgently ive made mwethod ocf creating a mail and sending it it arabic it works when it is sent to a outlook client but when its sent to hotmail its mumble jumble
any ideas my code is below

Response.ContentEncoding =Encoding.GetEncoding("Windows-1256");


string encodedString = Encoding.GetEncoding("Windows-1256").GetString(Encoding.GetEncoding("Windows-1256").GetBytes(txtEmailBody.Value));


msg.Server = System.Configuration.ConfigurationSettings.AppSettings["ServerValue"];
msg.FromAddress = "bbb@bbb.com";
msg.AddTo(TO.Text);
msg.Subject = "subbject";
msg.Body = Server.HtmlEncode(encodedString);
msg.ContentTransferEncoding = MailEncoding.QuotedPrintable;
msg.CharSetHeader ="Windows-1256";
msg.CharSet = "Windows-1256";
msg.send();
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top