我正在尝试使用 Perl、Win32::OLE 以及来自 InternetExplorer.Application。 microsoft.com/en-us/library/aa752084%28VS.85%29.aspx" rel="nofollow noreferrer">MSDN。我的目标是尽可能全面地了解 IE 正在做什么。 (与这个问题相关。)
IE当程序完成处理某个 URL 的各个阶段(NavigateComplete2
、DownloadComplete
DocumentComplete
)时,使用事件来通知我的程序。它还可以告诉我的程序它遇到的各种错误(NavigateError2
)。我认为我的问题的一部分已经得到很好的解决。
我还希望能够可靠地检测 IE 是否被服务器重定向。我主要担心 HTTP 30x 状态代码。有没有办法做到这一点,无论是通过 COM 自动化还是通过其他途径?
I am trying to control an InternetExplorer.Application
via the COM interface, using Perl, Win32::OLE
, and information from MSDN. My goal is to get as good an idea as possible about what IE is doing. (Related to this question.)
IE uses events to notify my program when it has finished various stages of processing a certain URL (NavigateComplete2
, DownloadComplete
DocumentComplete
). It can also tell my program about various errors it encounters (NavigateError2
). I consider that part of my problem solved well enough.
I would also like to be able to reliably detect if IE is redirected by the server. Primarily, I'm concerned about HTTP 30x status codes. Is there a way to do this, either with COM automation or via another route?
发布评论
评论(1)
嗨 Hillu。
我使用 WatiN 来弯曲 Internet Explorer符合我申请的意愿。
我认为你不能将 Perl 与它一起使用。但无论如何它可能会有所帮助。
它是一个不错的 .NET 库,已有近 5 年的历史,致力于 Internet Explorer 的自动化,最初是为了加快 Web 应用程序的测试而开发的。
它的一些功能:
我确信您是否查看过它的< a href="http:///watin.sourceforge.net/doc" rel="nofollow noreferrer">文档 你会发现一些有用的东西来帮助你解决你的问题,如果没有,我认为这个博客< href="http://watinandmore.blogspot.com/2008/04/捕捉-server-errors-with-watin.html" rel="nofollow noreferrer">帖子将为您提供一种简单的检查方法如果 IE 打开服务器错误页面。
希望有帮助。法比奥
Hi Hillu.
I use WatiN to bend Internet Explorer to the will of my applications.
I don't think you can use Perl with it. But any way it might help.
Its a nice .NET library with almost 5 years, its devoted to the automation of Internet Explorer, first developed to speed up testing of Web Applications.
Some of its features:
I'm sure if you have a look around its documentation you will find something of use in helping you with your problem, and if not i think this blog post will give you a simple way of checking if IE as turned a server error page.
Hope it helps. Fábio