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

Free Support Forum - aspose.com

Charts to images conversion issues

There are some issues when converting an excel chart to an image with Aspose Cells.

For the first image, “RB_OPR_G_UEL-Entw_02.png”:

The green textfield has the text: “Auslastung Aufgreifkriterium”

The green textfield has the text “Auslastung”.

This seems to be an overflow issue, for example if we remove the space between the two words, it will generate correctly. If we add another 1 letter word after the combined words, then that letter will not be generated.

The dates of the labels are in the format “Month/ Year”; example: “Dez/ 17”

The dates of the labels are in the format “Month. Year”; example: “Dez. 17”

For the second image, “RB_OPR_G_UEL-Vert_02.png”:

Only “DDD…” label is present on the Ox axis

There are extra labels appearing for the Ox axis like “AAA…”, “BBB…”

The label “DDD…” is on a single line.

The label “DDD…” is wrapping on the second line.

Here is the code reproducing these issues:

     Tuple< string, string>[] inputData = {
     Tuple.Create( "RB_OPR_G_UEL-Entw_02",  "\\RB_OPR_G_UEL-Entw_02.png"),
     Tuple.Create( "RB_OPR_G_UEL-Vert_02",  "\\RB_OPR_G_UEL-Vert_02.png"), 

    var imageOrPrintOptions = new ImageOrPrintOptions
        Quality = 100,
        VerticalResolution = 200,
        HorizontalResolution = 200,
        PrintingPage = PrintingPageType.Default,
        ChartImageType = ImageFormat.Png,
        OnePagePerSheet = true,
        OnlyArea = true

    foreach (var input in inputData)
        using (FileStream fs = File.OpenRead(Server.MapPath("/File") + "\\Input.xlsx"))
            var workbook = new Workbook(fs);
            var chart = workbook.Worksheets["OpRisk_UEL Verteilung"].Charts[input.Item1];
            var image = chart.ToImage(imageOrPrintOptions);
            image.Save(Server.MapPath("/File") + input.Item2, ImageFormat.Png);

I have also attached the Web App reproducing this issues.
WebApp.zip (99.0 KB)


I tested your scenario/case a bit using your template file. There is some configuration issue regarding your used font “CorpoS” in the workbook on my end, will check it out soon. In the meanwhile could you please provide your output image(s) of charts using our latest version/fix: Aspose.Cells for .NET v22.2.

WebApp.zip (186.0 KB)
In the File folder there are the 2 images that I was referring to


Thanks for the image files.

Please notice, I have logged a ticket with an id “CELLSNET-50433” for your issue. We will look into your issue to figure out soon.

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


  1. For the text field with “Auslastung”, please make sure your scale in display setting is 100%
    Currently the text size we calculate is different at different scales.
  2. For the date of axis labels, the number format is “[$-de-DE]mmm/ yy;@”, we deal with the date format for the German system displayed as “Month.Year”. As a workaround you can cope with it by deleting “[$-de-DE]”.
  3. For The label “DDD…” is on a single line, it is difficult to make them display same as Excel when the interval between labels is set to automatic. However we will make some improvements in future and update you once done.