哪些开发工具支持webbrowser控件的事件? [英] What development tools support the webbrowser control with events?

查看:72
本文介绍了哪些开发工具支持webbrowser控件的事件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在web浏览器控制MS支持事件(原定为IE9错误,已于12月13日修复)的过程中,IE组支持代表试图在非托管VC ++中重新开发方向与MFC。

During the course of a webbrowser control MS support incident (which turned out to be an IE9 bug, fixed on Dec 13), the IE group support rep was trying to nudge me in the direction of redevelopment in unmanaged VC++ with MFC.

目前,我们有一个商业识字软件产品,其中包括用VB6编写的webbrowser控件。在Windows 7下以及Windows 8的预览版中工作正常。

Currently, we have a commercial literacy software product, which includes the webbrowser control, written in VB6. Works fine under Windows 7, and also the preview version of Windows 8.

但它可能在某些时候不起作用,我想开始使用它。我一直期待在C#中这样做,但根据代表,他指出了
http://support.microsoft。 com / kb / 934368 ,您无法使用.net可靠地处理文档事件。

But it probably won't work at some point, and I'd like to get started with something. I had been anticipating doing this in C#, but according to the rep, who pointed out http://support.microsoft.com/kb/934368 , you can't reliably handle document events using .net.

首先,我想知道webbrowser开发人员社区中是否存在协议。网不是真的可行(如果你正在捕捉事件)。如果是这样,这可能意味着唯一的MS开发环境是非托管VC ++,这似乎很奇怪。这b
也可能涉及一个可能较大的学习曲线,就像我们正处于市场营销之中一样是资源消耗!

First, I was wondering if there is agreement in the community of webbrowser developers that .net isn't really viable (if you're capturing events). If so, this may mean that the only MS development environment is unmanaged VC++, which seems odd. This would also involve a probably largish learning curve, and be a resource drain just as we’re in the midst of marketing!

其次,他们的其他开发环境是更轻松?我之所以选择VB6(我曾经是C程序员)的原因是Scott Roberts的IE5开发书有点建议将其作为一个开发代码快10倍b $ b(或类似的东西)的环境!

Second, are their other development environments that are easier? The reason I chose VB6 in the first place (I had been a C programmer) was that Scott Roberts' IE5 development book sort of suggested it as an environment in which one develop code 10x faster (or something like that)!

所有建议都表示赞赏!

Steve Siegel

Steve Siegel

推荐答案

IHMO .Net对于COM互操作的性能和稳定性是不可行的。
发布CLR COM包装器很危险
。在Visual Studio 2010中,Microsoft要求Marshal.ReleaseComObject的每个调用者调用该调用。正如您可能猜到的那样,这会导致COM对象的生存时间长于组件作者最初计划的
。 GC并不经常发生,有时程序员需要按Ctrl-Alt-Shift-F12两次强制GC。 

IHMO .Net isn't viable for performance and stability regarding COM interop. Releasing a CLR COM wrapper is dangerous. In Visual Studio 2010, Microsoft asks each and every caller of Marshal.ReleaseComObject to justify the call. As you probably guessed, this leads to COM objects living longer than the component authors originally planned. And GC does not happen often enough, sometimes programmers need to hit Ctrl-Alt-Shift-F12 twice to force a GC. 

还有其他选项,C ++不是唯一的母语(你之前选择的VB是另一种),但是比较那里的例子和教程的数量,如果你想快速获得一些东西,使用C ++可能是你最好的选择。

There are other options, C++ isn't the only native language (you previous choice VB is another), but comparing the amount of examples and tutorials out there, using C++ may be your best choice if you want to get something quick.

MFC已经您可以很容易地开始托管ActiveX的代码,但它不是唯一具有ActiveX托管支持的类库。我认为ATL是另一个很好的选择,因为它有更多的COM支持。如果您不喜欢为Visual Studio付费,那么
可以将您的代码基于Windows SDK中的TSTCON示例,或者使用其他具有ActiveX支持的C ++ frameworts。

MFC has code that you can start hosting an ActiveX pretty easily, but it isn't the only class library that has ActiveX hosting support. I think ATL is another excellent choice as it has much more COM support. If you don't like paying for Visual Studio, you can base your code on the TSTCON sample from Windows SDK, or use other C++ frameworts that has ActiveX support.

这篇关于哪些开发工具支持webbrowser控件的事件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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