Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Displaying pdf in WinForms webbrowser control under x64

I have an application that uses the webBrowser control provided by Microsoft to display a pdf to the user. It has been found that when the application is running under x64 the pdf will download and open in Adobe Reader and not display in the user control. (Reference: http://social.msdn.microsoft.com/Forums/en-US/winforms/thread/06ad960b-7c5e-459c-9261-ca9d0e4ac88f/) Has anyone found a workaround for this issue other than compiling the application in x86?

like image 969
PCG Avatar asked May 05 '11 21:05

PCG


1 Answers

That's to be expected; the 32bit PDF Reader Document Object is only loaded by the 32bit browser. When it's not there, you go down the normal file download codepath.

See also: http://blogs.msdn.com/b/ieinternals/archive/2010/01/13/web-browser-control-does-not-show-flash-or-silverlight-in-a-64bit-dot-net-application.aspx

like image 98
EricLaw Avatar answered Nov 18 '22 10:11

EricLaw