KB-56518: When generating a report, Error212 is displayed.

Question:

When generating a report, the following error is displayed: Error212: Couldn’t export PDF using font “Arial” because characters referencing this font could not be represented with the character encoding “WinAnsiEncoding”. How can I fix it?

Solution:

This happens because the font being used (Arial) does not support a certain character (such as Greek characters, for example) in the encoding being used by the PDF (WinAnsiEncoding). The error message suggests changing two PDF export properties (AcrobatVersion and SemiDelimitedNeverEmbedFonts).

To fix this, just use GetExportFilter method before exporting the report.

Example:

set reportFilter = report.GetExportFilter("PDF")
reportFilter.AcrobatVersion = 2
reportFilter.SemiDelimitedNeverEmbedFonts = ""
report.Export reportFilter, "C:\Report.pdf" 
Print Friendly, PDF & Email

Este artigo foi útil? Was this helpful?

Classificação média - Average rating 0 / 5. Count: 0

Leave a Reply

Your email address will not be published.Required fields are marked *