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

Free Support Forum - aspose.com

'Gdip' threw an exception with Dotnet Core 3.x app on Mac OSX

I am running a Dotnet core app (3.1) on a Mac (Catalina) and I’m trying to add an image to a PDF using this tutorial: https://docs.aspose.com/pdf/net/manipulate-images/.

I get an error when trying to add the imageStream.
"Invalid image stream (The type initializer for ‘Gdip’ threw an exception.)’.

Doing my research, this appears to be related to needing the libgdiplus library. I installed this with brew install mono-libgdiplus but I am still getting this error.

Aspose.Pdf: Version=“20.3.0”
Sample Project that can replicate the issue: https://github.com/duyn9uyen/aspose-add-image-to-pdf

Can someone help?

@dnguyendev

Meanwhile we are checking the issue, would you kindly try using Aspose.PDF for .NET 20.9 and install latest version of libgdiplus package at your side. Please let us know about the results. We will further proceed accordingly to assist you.

Same issue with Aspose.Pdf Version=“20.9.0” and the latest version of libgdiplus.

@dnguyendev

We have logged an investigation ticket for your case as PDFNET-48752 in our issue tracking system. We will further investigate this scenario in details and keep you posted with the status of ticket resolution. Please be patient and spare us some time.

We are sorry for the inconvenience.