Hi All,
Please help me!
I have a problem when exporting my chart to a PDF file.
Any text that contains special characters like öäüÖÄÜ, this are coming in the PDF file incorrect, although in the screen it's ok.
I have tried setting up the Charset to different type without success.
Is there any place else where can I set the Charset ?
Am I doing something wrong?
This is the code I am using:
protected void ImageButton1_Click(object sender, System.Web.UI.ImageClickEventArgs e)
{
GetEvaluationRating();
Steema.TeeChart.Export.PDFFormat pdfPage = new Steema.TeeChart.Export.PDFFormat(WebChart1.Chart);
MemoryStream mem = new MemoryStream();
pdfPage.Save(mem);
byte[] bytes = mem.GetBuffer();
HttpContext.Current.Response.Buffer = true;
HttpContext.Current.Response.Clear();
// HttpContext.Current.Response.Charset = "ISO-8859-1";
// HttpContext.Current.Response.Charset = "UTF-8";
HttpContext.Current.Response.Charset = System.Text.UTF8Encoding.UTF8.WebName;
HttpContext.Current.Response.ContentEncoding = System.Text.UTF8Encoding.UTF8;
HttpContext.Current.Response.ContentType = "application/pdf";
HttpContext.Current.Response.AddHeader("content-disposition", string.Format("attachment; filename=FsPe_Chart_{0}.{1}","007", "pdf") );
HttpContext.Current.Response.BinaryWrite(bytes);
HttpContext.Current.Response.Flush();
HttpContext.Current.Response.End();
}
Charset Export chart to PDFFormat wrong german spelt .NET
Charset Export chart to PDFFormat wrong german spelt .NET
Last edited by jdooley on Mon Sep 10, 2007 10:01 am, edited 1 time in total.
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi jdooley,
Yes, this is a known problem. We've been investigating a solution to this problem but a good solution hasn't been found yet.
Yes, this is a known problem. We've been investigating a solution to this problem but a good solution hasn't been found yet.
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |