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

Free Support Forum - aspose.com

Exception (HRESULT: 0x80131401) raised while trying to save

Hi

I am getting this exception:

A first chance exception of type ‘System.IO.FileLoadException’ occurred in Aspose.Pdf.dll
Additional information: Loading this assembly would produce a different grant set from other instances. (Exception from HRESULT: 0x80131401)

After running this code:
using (Document pdfDocument = new Document(stream, true))
{
PdfContentEditor contentEditor = new PdfContentEditor();
contentEditor.BindPdf(pdfDocument);
contentEditor.DeleteStampById(stampId);
pdfDocument.Save(stream);
}

Any ideas?

Hi Hezi,


Thanks for contacting support.

As per our understanding from error StackTrace, the issue appears to be related to that fact that API is facing some problem while accessing files required for some manipulation/operations. Therefore, can you please share a sample project along with sample/input files, so that we can test the scenario in our environment. We are sorry for this inconvenience.

Dump file will be good instead ?

Hi Hezi,


Thanks for contacting support.

The dump file will give us detailed idea about the exception, whereas the source file and code snippet will help us in replicating and debugging the issue in our environment.