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

Free Support Forum - aspose.com

Excel to PDF conversion - Keep Excel sheet grid lines in the output PDF in .NET

when I convert excel to pdf with aspose.cells, if I can keep the excel line still exists in the pdf?

Hi,


Thanks for your query.

You meant Gridlines (in Excel). Sure, you may make the gridlines visible for the worksheet(s) when rendering to PDF file format, see the following sample code for your reference:
e.g
Sample code:
Workbook book = new Workbook(“e:\test2\Book1.xlsx”);

Worksheet sheet = book.Worksheets[0];

sheet.PageSetup.PrintGridlines = true;

book.Save(“e:\test2\out1.pdf”);
Hope, this helps a bit.

Thank you.

Thanks Amjad Sahi, it’s really great!

Hi,


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

Thank you.

Thanks Amjad Sahi for your support, so far, here is the fastest reply forum I ever play with. Really helpful for me.