Page 1 of 1

OutOfMemory Crash when using ShowTextBlock

Posted: Fri Jan 26, 2018 3:01 pm
by whoit
Hi -

We recently implemented ShowTextBlock as our stamping method, and throughout all of our tests, everything works fine.
We have distributed a copy to one of our clients, and are now see this error:

2018/01/25 - 1:35:12 AM --- [processQFiles]: afranke: Conversion Failure - ERROR Placing Banner: System.OutOfMemoryException: Insufficient memory to continue the execution of the program. at PDFXCoreAPI.IPXC_Page.PlaceContent(IPXC_Content pContent, UInt32 nFlags)
at DynamicStamping.DynamicStamping.StampDocument(Int32 iPageNumber)
- 'Drawing Print' '9494553_C' '001' P_9494553_001_C_E12918_V.pdf: FAILED TO CONVERT

Any ideas what this could be?

Thanks,
Wayne

Re: OutOfMemory Crash when using ShowTextBlock

Posted: Fri Jan 26, 2018 3:08 pm
by Sasha - Tracker Dev Team
Hello Wayne,

Are you using the x86 version in the .Net application? Well it can happen in this case if you are using a vast amount of documents and you are forgetting to Close them and/or clearing the garbage collector (like in the FullDemo sample).

Cheers,
Alex

Re: OutOfMemory Crash when using ShowTextBlock

Posted: Fri Jan 26, 2018 3:33 pm
by whoit
Hi Alex -

We are using the x86 version (called from VB6).
We are Closing the documents.
We can test the garbage collector later today.

Are you saying this limitation does not exist in the x64 version?

-Wayne

Re: OutOfMemory Crash when using ShowTextBlock

Posted: Sat Jan 27, 2018 6:34 am
by Sasha - Tracker Dev Team
Hello Wayne,

As far as I remember, there were some topics on this matter already. In short, the .Net is very inefficient when it comes to memory usage - the heap can just pile up and the Garbage Collector won't ever release it. This can lead to such an errors in the x86 programs (as they have a direct memory limit).

Cheers,
Alex