.Net Exception from HRESULT: 0x800700C1

Q) 05:57:59 Failed to optimize document [7213040]. System.BadImageFormatException: Could not load file or assembly ‘PDFNet.dll’ or one of its dependencies. is not a valid Win32 application. (Exception from HRESULT: 0x800700C1)

This has been happening since I have got the updated DLL (Please see details in the below emails).

Could you please let me know what could be the issue for the BadImageFormat Exception?


A) The issue was neither with the dll nor with the code.

My colleague, found that the issue was because of an update from Microsoft for “A security issue has been identified leading to a vulnerability in MFC applications that are built with Visual Studio 2010 and ship the Microsoft Visual C++ 2010 Service Pack”.

After installing this update on the Prod machine, it works fine. http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=26999

It is most likely a VC redistributable issue - not MFC / security related