別のフレーム (名前または ID なし) に切り替えようとしていますが、例外が発生します。
object index = 0;
var frame = (mshtml.IHTMLWindow2)workDocument.frames.item(ref index);
frameDocument = (mshtml.IHTMLDocument2)frame.document; // Exception.
他の方法を試しましたが、同じ例外:
webBrowser.Document.Window.Frames[0].Document.GetElementById("userName").SetAttribute("value", username);
webBrowser.Document.Window.Frames[0].Document.GetElementById("userPassword").SetAttribute("value", password);
webBrowser.Document.Window.Frames[0].Document.GetElementById("login").InvokeMember("click");
例外:
アクセスが拒否されました。(HRESULT からの例外: 0x80070005 (E_ACCESSDENIED))
クロスドメインの理由であることは理解しています。その場合の解決策はありますか
ありがとう