Page 1 of 1

Exception in PdfFonts

Posted: Thu Mar 02, 2023 3:45 pm
by tijmen
We sporadically get this exception when exporting a document:

System.Exception: Exception in PdfFonts.GetFontMetrics, font 'Arial' step #0: 'An item with the same key has already been added. Key: 2048Regular'
at Stimulsoft.Report.Export.PdfFonts.GetFontMetrics(Font font, PdfFontInfo currentFontInfo, UInt16[] glyphMap, Boolean isWpf) in D:\Stimulsoft\Stimulsoft.Reports\Stimulsoft.Report\Export\Services\Pdf\StiPdfFonts.cs:line 766
at Stimulsoft.Report.Export.PdfFonts.InitFontsData(Boolean isWpf) in D:\Stimulsoft\Stimulsoft.Reports\Stimulsoft.Report\Export\Services\Pdf\StiPdfFonts.cs:line 1287
at Stimulsoft.Report.Export.StiPdfExportService.ExportPdf1(StiReport report, Stream stream, StiPdfExportSettings settings) in D:\Stimulsoft\Stimulsoft.Reports\Stimulsoft.Report\Export\Services\StiPdfExportService.cs:line 8118
at Stimulsoft.Report.Export.StiPdfExportService.ExportPdf(StiReport report, Stream stream, StiPdfExportSettings settings) in D:\Stimulsoft\Stimulsoft.Reports\Stimulsoft.Report\Export\Services\StiPdfExportService.cs:line 7170
at Stimulsoft.Report.StiReport.ExportDocument(StiExportFormat exportFormat, StiExportService exportService, Stream stream, StiExportSettings settings) in D:\Stimulsoft\Stimulsoft.Reports\Stimulsoft.Report\StiReport.Export.cs:line 704

Stimulsoft version is 2023.1.2.

This is potentially related to viewtopic.php?p=166130 (when processing multiple documents concurrently during load).

Re: Exception in PdfFonts

Posted: Fri Mar 03, 2023 4:01 pm
by Lech Kulikowski
Hello,

That issue was fixed. Please check the last release build.

Thank you.