Hi,
we have an issue with a high memory usage from some documents. We are using Aspose.Net functions from a native Win32 application via CrossTalk (which allows usage of .Net libraries with Delphi). We are running this setup for almost two years now without having any issue like this before:
We have a document causing an exception in the Document constructor. Running the same document in a .Net environment only works without an exception but is also causing very high memory usage. The document has a file size of ~20MB, but loading the document via Aspose will require about 800+ MB:
image.png (9.5 KB)
This can be reproduced by running the following simple code:
var doc = new Document(@"S:\tmp\CAST EXCEPTION.doc");
I assume that the high memory usage is causing the problems inside our Win32 scenario. I wrote a little test tool to debug the scenario (for some reasons inside the test tool the exception only occurs with a very high memory load, in our real application we only have a basic memory usage of ~150 MB).
In Visual Studio you can set our test tool as host application which should be ran by the debugger, press the button and debug Exception while loading in the .Net library project:
image.png (17.6 KB)
I hope you can get us some help solving the problem. I attached you an archive including the document, a .net library project for reproduction and our delphi test tool (including its source codes). As the archive seems to be too big to be uploaded I uploaded it to one of our FTP servers and added you a file with a downloadlink. Please reply as soon as you have locally downloaded the document and projects so we can delete it from the FTP server.
download.zip (216 Bytes)
Kind Regards,
Daniel