Article ID: 942443 - View products that this article applies to.
This article has been archived. It is offered "as is" and will no longer be updated.
If you create several hundred XML Paper Specifications (XPS) in one batch in a Microsoft Windows Presentation Foundation application, you may encounter a memory leak in the event handler. Additionally, a System.ComponentModel.Win32Exception exception may occur.
To work around this problem, preload the PresentationCore.dll file or the PresentationFramework.dll file in the primary application domain. Preload the file before the secondary application domain runs any Windows Presentation Foundation code. This operation adds the natively generated images into memory. Additionally, this operation prevents the problem.
Contact us for more help
Connect with Answer Desk for expert help.