Welcome Guest Search | Active Topics | Sign In | Register

EO:WebControl display PDF Options
Piotr
Posted: Wednesday, February 19, 2014 11:16:53 AM
Rank: Newbie
Groups: Member

Joined: 2/18/2014
Posts: 3
I am trying to display pdf (local and from web) using WPF WebControl, but every time i see only black screen. Web browser works well when opening HTML files. I tried this using example TabbedBrowser but result was the same. I am using VS 2012.

Here is my code:

<Grid>
<eo:WebControl Grid.Row="0" Visibility="Visible" Name="webBrowser" Background="Transparent" Margin="0,0,0,43">
<eo:WebControl.WebView>
<eo:WebView Url="C:\test.pdf" />
</eo:WebControl.WebView>
</eo:WebControl>
</Grid>

When i open source i can see:

<html><body marginwidth="0" marginheight="0" style="background-color: rgb(38,38,38)"><embed width="100%" height="100%" name="plugin" src="file:///C:/test.pdf" type="application/pdf"></body></html>

I thought that background is covering file that is why i tried to change it but it has no effect. Is there way to fix it or some work around ?

Thanks !

eo_support
Posted: Wednesday, February 19, 2014 1:04:40 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,196
Hi,

Please check whether you have Adobe Reader installed on your machine. Installing Adobe Reader will install the browser plug-ins needed to render PDF file. Recently browsers such as newer version of Chrome and IE has built-in code to display PDF file and it does not need such plug-ins. However EO.WebBrowser doesn't have that part built-in yet, so it still need the standalone plug-in.

Thanks!
Piotr
Posted: Wednesday, February 19, 2014 4:18:15 PM
Rank: Newbie
Groups: Member

Joined: 2/18/2014
Posts: 3
I have Adobe Reader installed, but thank to your reply i found the problem. I switched PDF plugin in Chrome to Adobe and then trying to open html from my first post I received error message that PDF plugin crashed . Following instruction from Adobe forum i managed to fix it http://forums.adobe.com/message/5629884 .

Thanks !
eo_support
Posted: Wednesday, February 19, 2014 4:36:44 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,196
Ah. Thank you very much for sharing!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.