Fix Adobe Acrobat PDF Preview Handler COMException in WinForms
Question details
The user needs to restore PDF previews in a .NET WinForms application after upgrading Acrobat Reader from 32-bit to 64-bit.

- Product
- Adobe Acrobat Reader PDF preview handler and .NET WinForms
- Device & OS
- Windows; version not provided
- Scenario
- A WinForms application calls IPreviewHandler.DoPreview to display a PDF after a Reader architecture change.
- Observed behavior
- DoPreview throws a COMException with E_FAIL, although PDF previews still work in Windows Explorer and Outlook.
Check the installed Acrobat Reader architecture and the WinForms process architecture in Task Manager's Details tab. In Visual Studio, check the project's Platform target and whether Prefer 32-bit is enabled.
Build the WinForms application for 64-bit Acrobat Reader
Use an explicit x64 build to test the application with the installed 64-bit Reader and its preview handler.
In Visual Studio, open the WinForms project's Properties, select Build, and set Platform target to x64. If applicable, disable Prefer 32-bit.
Use Build > Rebuild Solution, launch the rebuilt application, and check its architecture in Task Manager's Details tab.
Open a PDF through the application's preview feature and check whether the IPreviewHandler.DoPreview call succeeds.
If the error remains, inspect the PDF preview-handler registration in Registry Editor under HKEY_CLASSES_ROOT\.pdf and its associated file type. Confirm that it points to the intended installed handler.

Test an x86 build with 32-bit Acrobat Reader
Use this approach if the application must remain 32-bit and an x64 build is not suitable.
Open PDFs and Office files with WPS Office
WPS Office is a free, lightweight alternative for viewing PDFs and working with Office documents in a familiar interface. Its format support makes it easy to move existing files, but it does not repair your application's Adobe COM preview handler.

Frequently Asked Questions
Why does the PDF preview work in Explorer but fail in my application?
Explorer and Outlook may activate or host the preview handler differently from your WinForms application. Check the application's process architecture, handler registration, and preview-host implementation rather than assuming Explorer's success rules out a configuration issue.
Where can I change the WinForms application's architecture?
In Visual Studio, open the project Properties > Build and set Platform target to x64 or x86. Rebuild the solution and verify the running process in Task Manager.
Does Any CPU always run a .NET application as 64-bit?
No. The selected runtime architecture can depend on the environment and settings such as Prefer 32-bit. Use an explicit x64 or x86 platform target when testing an architecture-related preview issue.
Will matching Reader and application bitness always fix E_FAIL?
No. Matching bitness is a useful troubleshooting step, but COM can also work across architectures through an out-of-process server. If the error persists, inspect the handler registration and the application's preview-host implementation.




