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

Free Support Forum - aspose.com

Excel sheet save to PDF doc: how to avoid blank page generated?

I am saving a xlsx sheet to PDF file, the newly created PDF file contains blank page after each table page. Is there any setting to turn it off? Here are the code:

_asposeOrigWorkbook = new Workbook("c:\\Executive Budget v Goal.xlsx");
_asposeUpdatedWorkbook = new Workbook();
_asposeUpdatedWorkbook.save("c:\\Executive Budget v Goal.pdf")

you can see from my attached files, there are extra blank page shown up in PDF file.


Thanks for your posting and using Aspose.Cells for Java.

Aspose.Cells renders PDF in a same way as MS-Excel renders PDF in Print Preview. If you check your workbook in MS-Excel Print Preview, you will see blank pages are also there. So it is not a bug of Aspose.Cells.

If you want to get rid of blank pages, you can save your pdf as


PdfSaveOptions opts = new PdfSaveOptions();


_asposeUpdatedWorkbook.save(filePath + “.out.pdf”, opts);