Chart legend is rendered in wrong position when converting Excel sheet to image



When converting a sheet with a chart to an image, I noticed the position of the top legend is wrong.

var workbook = new Workbook(@"test.xlsx");
var options = new ImageOrPrintOptions
ImageFormat = ImageFormat.Emf,
OnlyArea = false,
TextRenderingHint = TextRenderingHint.ClearTypeGridFit,

OnePagePerSheet = true,


new SheetRender(workbook.Worksheets["Sheet1"], options).ToImage(0, @"est.emf");

I've attached the test file and the output image for your reference. You can find the legend position in the image is different from Excel.

Could you please take a look into this?




Thanks for your posting and using Aspose.Cells.

We were able to observe this issue and logged it in our database for an investigation and for a fix. 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

  • CELLSNET-45441 - Chart legend is rendered in wrong position when converted to image



Are there any updates on this?



Thanks for your posting and using Aspose.Cells.

We are afraid there is no update for you at this moment regarding this issue. However, we have logged your comment in our database against this issue and requested the product team to provide some fix or ETA for this issue. Once there is some news for you, we will update you asap by posting in this thread.



Please provide us these files again as used in your code. Thanks for your cooperation.

Attachment: test.png

#6 (13.8 KB)



Thanks for the files, we have logged them against this ticket for product team.

However, I have noted one thing, if you enlarge your chart, the position of the legend changes as well.

Here is a screenshot for your reference.

sc.png (43.2 KB)



We have looked into this issue and we are afraid, we don’t find any problem in test.xlsx. The result is same as Microsoft Excel.

Please check this attachment for your reference.

Download Link (94.9 KB)



Please check the highlighted area in the screenshot of your attachments which is very different

test.png (87.0 KB)



Thanks for your image and using Aspose API.

We have logged your provided image as well as your comment against this issue for product team evaluation. Please spare us some time, we will look into it and update you asap.



Please try our latest version/fix: Aspose.Cells for .NET v17.8.1:
Aspose.Cells for .NET v17.8.1 (.NET 2.0)
Aspose.Cells for .NET v17.8.1 (.NET 4.0)

Your issue (logged earlier as “CELLSNET-45441”) should be fixed in it.

Let us know your feedback.

Thank you.


The issues you have found earlier (filed as CELLSNET-45441) have been fixed in Aspose.Cells for .NET 17.9.