Hi Everyone,
i am trying to convert an HTML to PDF using RadFlowDocument. In HTML we have Greek Letters in the text and the export seems to ingore them and they are not printed in the final PDF.
This is a sample of my code:
<code>
string html = "<p>Greek Characters</p><p>Ε</p>";
var providerPdf = new Telerik.Windows.Documents.Flow.FormatProviders.Pdf.PdfFormatProvider();
var memoryStream = new MemoryStream();
var providerHtml = new Telerik.Windows.Documents.Flow.FormatProviders.Html.HtmlFormatProvider();
providerHtml.ExportSettings.ImagesExportMode = Telerik.Windows.Documents.Flow.FormatProviders.Html.ImagesExportMode.Embedded;
providerHtml.ExportSettings.ImageExporting += (s, e) =>
{
e.Handled = false;
e.Title = "Test image";
e.ExportSize = true;
e.AlternativeText = "You will see this text if the image is not loaded";
};
RadFlowDocument document = providerHtml.Import(finalHtml);
providerPdf.Export(document, memoryStream);
using (Stream output = File.OpenWrite(@"C:\TempThanasis\sample.pdf"))
{
providerPdf.Export(document, output);
}
</code>
Thanks