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

Free Support Forum - aspose.com

Partial conversion of Excel file to pdf

Hello,
A portion of the content in Sheet2(English 2 of 2) of this Excel File Excel file is not getting converted to pdf.
Can you please let me what is the issue.?

Also attached image (showing error) and the converted pdfErrorInSheet2.pdf (47.9 KB)

Thank you.

@sgkrishna

Your inquiry is related to Aspose.Cells and we are moving your this post to respective category where you will be assisted shortly.

@sgkrishna,

Thanks for the template file and PDF file.

I checked your template file and found a print area (“B1:AC10”) is set for the second sheet (check Page Setup| Sheet tab). That’s why you are getting partial conversion. Even you may take the print preview of the sheet in MS Excel manually and can see same display as per output PDF by Aspose.Cells APIs. Please either remove the printable area in MS Excel manually and re-save the file and then use your code to convert to PDF file. Alternatively, you may try the following sample code for the task, so the whole worksheet should be rendered:
e.g
Sample code:

.......
 Worksheet worksheet = workbook.Worksheets[1];

            worksheet.PageSetup.PrintArea = "";
......

Let us know if you still find any issue.

Thank you for the support. It worked.

@sgkrishna,

Good to know that your issue is sorted out by the suggested code. Feel free to contact us any time if you need further help or have some other issue or queries, we will be happy to assist you soon.