Saving an ex cel sheet with charts as html misplaces the chart in the html

dear support,

I am running aspose.cells rev 18.3 since some time now.
I observe that the placement of the chart chnages when an excel worksheet is saved in html format.
Attached you will find a sample excel and html file (53.9 KB)


Thanks for the template file and details.

Please try our latest version/fix: Aspose.Cells for .NET v19.3.4 (attached)
Aspose.Cells19.3.4 For .Net2_AuthenticodeSigned.Zip (4.9 MB)
Aspose.Cells19.3.4 For .Net4.0.Zip (4.9 MB)

I did test by converting your template file to HTML file format with v19.3.4, it works fine and same way as per MS Excel, the position of the right chart is ok. Please note, the bottom left chart is advanced MS Excel 2016 chart, I am afraid, Aspose.Cells does not support this chart when parsing to HTML.

hello, I tried the (unlicensed) latest version of aspose.cells and the image is still shifted.
I added the screenshot of the html and xlsx side by side.
code is equally simple :
Dim x As New Aspose.Cells.Workbook(“C:\MWorks\Webpages\MWorks_PlantViews\Reports\test.xlsx”)
x.Save(“C:\MWorks\Webpages\MWorks_PlantViews\Reports\test.html”, Aspose.Cells.SaveFormat.Html)

ScreenHunter_1048 Apr. 05 15.36.jpg (168.6 KB) (61.5 KB)


Thanks for the sample files and screenshot.

See the attached HTML file (in the zipped archive) which is generated by Aspose.Cells for .NET v19.3.4, you will notice it works fine when opening the file into the browser.

Please make sure that you are using the latest fix/version. I think you may print the version number (at the start of your program) of the fix/version:
Sample code:


Let us know if you still find any issue. (34.9 KB)

I am sorry, but the sizes are incorrect, and I am absolutely using the latest version.
in attachment you see a screenshot of the excel, the resulting html file and the version recorded in cell A1.
Are there any other setting that might affect the output ?

ScreenHunter_1049 Apr. 05 17.15.jpg (225.5 KB)


It seems that you have sent a different image “ScreenHunter_1049 Apr. 05 17.15.jpg” whose respective XLS file is not available.

I have tested the test.xls file using Aspose.Cells for .NET 19.3.x from NuGet package manager and created the HTML file (without license). I am afraid that no issue is observed and proper output file is created. Here complete solution and output files are attached for your reference.

Please give it a try and share the feedback. If issue is still there, please share simplest console application (runnable complete solution) for our reference. We will test the issue here and provide assistance accordingly. (61.8 KB) (31.6 KB)


By the way, please verify that Display setting is set to 100% when using the API to render your Excel file to HTML file format. For your information, Aspose.Cells works as MS Excel does. If you still do not want to change the display setting for os, you may try the following line at the start of the program if it makes any difference:
Sample code:

CellsHelper.DPI = 96;
// your code goes here.

Thanks for your mail,

When I introduce the statement…
Aspose.Cells.CellsHelper.DPI = 96
into the code, it works properly, without it, it does not.
When looking into the debug windows, it has a default value of 120.

I am unsure where this setting comes from.
Are there any associated setting that are of importance when saving into the html format ??



Good to know that your issue is sorted out when setting the DPI attribute to “96”. Well, you you may also set DPI setting of your computer to 100% display settings of your os. Well, we actually get DPI settings details using .Net API Graphics.DpiX/DpiY, etc. For your information, Microsoft Excel changes layouts with different DPI settings. And, we works Ok in DPI setting set to 100%.