Hi Aspose Team,
I have an issue while converting the excel file to PNG using ‘Aspose.cells’. It’s shown ‘Dotted Line’ instead of Line in PNG file.
Sample Code:
public void ExceclToPNG()
{Workbook book = new Workbook("Test.xlsx"); Worksheet sheet = book.Worksheets[0]; sheet.PageSetup.LeftMargin = 0; sheet.PageSetup.RightMargin = 0; sheet.PageSetup.TopMargin = 0; sheet.PageSetup.BottomMargin = 0; sheet.PageSetup.PrintGridlines = true; ImageOrPrintOptions imgOptions = new ImageOrPrintOptions(); imgOptions.ImageType = Aspose.Cells.Drawing.ImageType.Png; imgOptions.OnePagePerSheet = true; imgOptions.IsCellAutoFit = true; imgOptions.PrintingPage = PrintingPageType.IgnoreBlank; SheetRender sr = new SheetRender(sheet, imgOptions); Bitmap bitmap = sr.ToImage(0); bitmap.Save(@"C:\Images\" + "Output_Excel.png"); }
Input File :Test.zip (12.1 KB)
Output:Output_Excel.png (5.0 KB)
Expected:Expected_Excel.png (6.0 KB)
Could you please help us to solve the issue.
Thanks.