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

Free Support Forum - aspose.com

Formatting is lost during conversion from Excel to PDF

Hi,

I am trying to convert the excel report to PDF using Java cell, in the attached excel the wrapping formatt of Bank Name and years is lost during conversion to PDF.

Please let me know how to fix this.

Regards,

Abhinav

Hi,

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

We were able to replicate this issue using the latest version Aspose.Cells
for Java v7.4.3.5
with the following code. Your ReportResult.xls is also a corrupt file because it shows warning when it is opened in Ms-Excel 2010.

We have logged this issue in our database. We will look into it and resolve this issue. Once the issue is resolved or we have some other update for you, we will let you know asap.

This issue has been logged as CELLSJAVA-40534.

Java


String filePath=“F:\Shak-Data-RW\Downloads\ReportResult.xls”;


Workbook workbook = new Workbook(filePath);


workbook.save(filePath + “.out.pdf”, SaveFormat.PDF);

Thanks for the response.

Hoping to get the solution soon.

Is there any update on this issue.

This issue has been logged as CELLSJAVA-40534.

Hi,

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

We are afraid, there is no update for you at this moment. However, we have logged your comments in our database against this issue. Once, there is some update for you, we will let you know asap.

Hi,

Thanks for your posting and using Aspose.Cells.

Please auto fit rows before converting to pdf. If worksheet
does not set row height explicitly, MS-Excel will autofitrows when open
it.

We will not autofit worksheet unless user write following code:



Java


for(int i=0; i<book.getWorksheets().getCount(); i++)

{

Worksheet ws = book.getWorksheets().get(i);

ws.autoFitRows(true);

}