【问题标题】:Read iframe content using Webbrowser C#使用 Webbrowser C# 读取 iframe 内容
【发布时间】:2011-10-10 07:54:49
【问题描述】:

我知道我可以使用 webbrowser 的以下属性访问所有 iframe: 字符串 html = webBrowser1.Document.Window.Frames[0].WindowFrameElement.InnerText;

但我正在努力解决跨域限制.. 我的文档网址就像 www.subdomain1.sport.com/... 而 iframe 网址就像 www.subdimain2.sport.com/...

如何访问 iframe 内容并将一些文本放入输入标签中?

【问题讨论】:

    标签: c# iframe browser cross-domain innertext


    【解决方案1】:

    我认为你必须参考以下 URL 来获取跨域存在的 IFrame 的内容。

    http://codecentrix.blogspot.com/2008/02/when-ihtmlwindow2document-throws.html

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2011-01-28
      • 1970-01-01
      • 2016-11-08
      • 1970-01-01
      • 1970-01-01
      • 2012-08-20
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多