Free Support Forum -

Issues in creating thumbnail of charts/table

We are using Aspose.Slides library to extract data from PPT .
we are facing issues while creating thumbnail for tables/charts .Issue is below mentioned exception
Parameter is not valid. at System.Drawing.Bitmap…ctor(Int32 width, Int32 height, PixelFormat format)

This issue comes only when we are running application in Linux containers , when inw erun in IIS it works fine.

Thank you for your request. To help you, we need to know the next things:

  • The version of Aspose.Slides you used
  • The PPT file you mentioned
  • The code example reproducing the issue
  • The version and distribution of Linux

Aspose.Slides.Net => 21.3

PPT can not be shared

using (var ms = new MemoryStream())
var presentation = new Presentation(ms);
var slideShapes= presentation.Slides[slide.SlideNumber].Shapes;
var chrt = slideShapes.OfType()[0]
IShape chrt
chrt.GetThumbnail().Save(ms, ImageFormat.Png);

            catch (Exception ex)


It is an dotnet core (3.1)app running in Linux container

Thank you for the additional information.

You can compress the file to a ZIP archive and upload it.

I am really sorry , I am not allowed to share the PPT file it belongs to an client . I am using Debian 10 image for my container.

I debugged the issue and found that width of chart is 466.43 which is floating point value and I think Bitmap constructor needs int values .
Please let me know if anything else is required.

But i am not able to understand how it works in IIS.

We are doing our best to help you. But unfortunately, we cannot reproduce the issue and find out the causes without that PPT file in your case. As a workaround, try to create a similar presentation with the same error. (483.7 KB)
Hi Andrey , I am attaching ppt which has graph who throws exception on calling GetThumbnail method.
I again tried and I am sure that it works fine on IIS but thows exception while running in Linux container.
Can you please provide us the solution asap ?

Thank you for the presentation sample. I managed to reproduce the error. I’ve logged the issue in our tracking system with ID SLIDESNET-42554. Our development team will investigate this case. You will be notified when it is fixed.

I requested an estimated time to fix the issue from our development team. I will let you know when it is possible.

Do we have any updates on this?

The issue investigation will be starting next week.

Has the investigation started on this issue ?

Our development team has been working on this issue. A fix will be released in Aspose.Slides 21.6.