通过WebBrowser使用WindowsFormsHost查看PDF文件的区别? [英] Difference in using WindowsFormsHost over WebBrowser to view PDF files?

查看:141
本文介绍了通过WebBrowser使用WindowsFormsHost查看PDF文件的区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在创建一个将大量使用PDF文件查看功能的应用程序.通过WebBrowser使用WindowsFormsHost是否有区别/优势? WebBrowser与WindowsFormsHost设置仅是一行代码.因此,我很好奇使用WindowsFormsHost是否有任何优势?

I'm creating an application that will heavily use PDF file viewing. Is there a difference/advantage in using WindowsFormsHost over WebBrowser? WebBrowser is just a line of code versus WindowsFormsHost setup. So, I'm curious if there are any advantages of using WindowsFormsHost?

推荐答案

WPF WebBrowser控件默认情况下在IE保护模式下运行,并且Adobe PDF Reader插件已知与此有关.检查此问题.我会选择WindowsFormsHost并直接托管PDF Reader ActiveX,操作方法.

WPF WebBrowser control runs in IE protected mode by default, and Adobe PDF Reader plugin is known to have issues with that. Check this question. I'd go with WindowsFormsHost and host PDF Reader ActiveX directly, here's how.

这篇关于通过WebBrowser使用WindowsFormsHost查看PDF文件的区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆