Chart to PDF - Arrow problem


I am using Aspose cells

In PDF of Chart 1, Arrows in the pdf or jpeg output are not matching the input in Excel Spreadsheet.

Following is the code snippet being used to generate PDF files:
Workbook workbook = new Workbook(“C:/temp/ChartIssue.xlsx”);

WorksheetCollection ws = workbook.getWorksheets();
Worksheet sheet1 = ws.get(“wo cons charts”);
Chart chart = sheet1.getCharts().get(“Chart 2”);
ChartShape cshape = chart.getChartObject();
int sheetIndex = ws.add();
Worksheet worksheet = ws.get(sheetIndex);

//Setting the name of the newly added worksheet
String transientSheetName = “TransientWorksheet”;

//Copy the Chart to Second Worksheet
worksheet.getShapes().addCopy(cshape, 0, 0, 0, 0);

//Get the new chart and set its height and width accordingly
Chart chart1 = worksheet.getCharts().get(0);
//Making remaining sheets invisible as the output is required for only TransientWorksheet
for (int i = 0; i < ws.getCount(); i++) {
String sheetName = ws.get(i).getName();

PdfSaveOptions pdfSaveOptions = new PdfSaveOptions();


worksheet.getPageSetup().setLeftMargin(0);“c:/temp/Asposegenerated.pdf”, pdfSaveOptions);

Can you please look into this issue?



Thanks for providing us template file and sample code.

After an initial test, I observed the issue as you mentioned. I found that leading arrows in the PDF or JPEG output are not matching with the input in the Excel spreadsheet. I used the template and sample code you provided to reproduce the issue. I have logged a ticket with an id “CELLSJAVA-41498” for your issue. We will look into it soon.

Once we have any update on it, we will let you know here.

Thank you.


Please try our latest version/fix: Aspose.Cells for Java v8.6.2, you may download it here:

Please try using Chart.toPdf() method directly to generate chart report.

Let us know your feedback.

Thank you.


I am using Aspose.Cells v8.6.2.4. To generate the PDF, I am using chart.toPdf() method.
Unfortunately, this issue still exists. A few arrows are overlapping with the chart’s labels.

I am attaching a screenshot of the issue along with the PDF generated.

Can you please analyse this issue.


Thanks for the sample file.

I have re-evaluated your issue using our latest version/fix: Aspose.Cells for Java v8.6.2.4. Well, Aspose.Cells renders the chart as per what is shown in Print preview taken (for the chart) in MS Excel. I found it displays the same way as per Ms Excel’s print preview, see the screen shot for comparison and for your reference:

Thank you.


Although there is considerable improvement in the output but the arrows are still overlapping with the text. They should render exactly as they are in excel.

Attachments: (154.2 KB)

Can you please analyse this.



Thanks for the template files and screenshot.

Well, Aspose.Cells follows MS Excel standards. If you could take the print preview of the chart in MS Excel manually, you will also see this issue as per your screenshot (the arrow is overlapping with ‘g’ and is more thick) you mentioned, see the screenshot for your reference:

Thank you.

The issues you have found earlier (filed as ) have been fixed in this update. This message was posted using BugNotificationTool from Downloads module by MuzammilKhan