获取从ac#应用程序创建的IE popupwidow的状态
我使用 C# 创建了一个 Internet Explorer 工具栏。单击该工具栏按钮后,我想打开 Internet Explorer 弹出窗口。我在表单中使用了 Web 浏览器控件及其调用脚本方法。在java脚本中,我使用window.open方法来打开新的弹出窗口。我需要在表单中确定弹出窗口是否关闭?
I have created an internet explorer toolbar using C#. On clicking on that toolbar button , I want to open internet explorer popup window. I have used web browser control with in the form and its invoke script method. With in the java script I have used window.open method to open the new window popup. I need to identify whether the popup is closed or not with in the form?.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
由于这是来自 Windows 应用程序内部,因此您可能会发现使用自己的(可见)WebBrowser 控件创建单独的表单更容易,并将其 Url 属性设置为您在 javascript
window.open方法。
以下是如何通过按钮的单击事件执行此操作的简单示例:
Since this is from within a Windows application, you might find it easier to create a separate form with its own (visible) WebBrowser control, with its Url property set to whatever address you were using in the javascript
window.open
method.Here is a simple example of how to do this from a button's click event: