We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Excel 2 PDF conversion. Font family and size different


Have a new problem with Excel 2 PDF conversion

As you can see in the attached excel file all cells have similar font family and size. But in the resulting PDF paragraph and looks different.

Can you help us to fix this problem?

Vladimir, LOIS.


Thanks for the template file and output PDF file.

After an initial test, I observed the issue as you mentioned by converting your template Excel file to PDF file format. I found that Font family and size are different in Excel to PDF rendering. I noticed all cells have similar font family and size but in the resulting PDF paragraph and (shaded section) looks different as you pointed out.
Sample code:

String filePath = “polisNs1.xls”;
Workbook wb = new Workbook(filePath);
wb.save(filePath + “.out1.pdf”);

I have logged a ticket with an id “CELLSJAVA-41815” for your issue. We will look into it soon.

Once we have an update on it, we will let you know here.

Thank you.


Thanks for using Aspose.Cells.

If you check MS Excel generated pdf, the second last character (it is like an upper “4”) of paragraph and (shaded section) is not “Times New Roman” font. Because “Times New Roman” font cannot show the character, so we change the font of the Cell.

A workaround is to change the character to the character “4” and set it to be superscript as we shared in the attachment.