Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/267.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 如何获取iframe内部标记";textarea";在webbrowser控件c中#_C#_Winforms_Webbrowser Control - Fatal编程技术网

C# 如何获取iframe内部标记";textarea";在webbrowser控件c中#

C# 如何获取iframe内部标记";textarea";在webbrowser控件c中#,c#,winforms,webbrowser-control,C#,Winforms,Webbrowser Control,我正在尝试在文本框中获取完整的iframe <textarea id="embed_code" spellcheck="false" onclick="this.select()" style="opacity: 1;"> <iframe frameborder="0" width="480" height="270" src="http://www.dailymotion.com/embed/video/x18adty"></iframe> <

我正在尝试在文本框中获取完整的iframe

<textarea id="embed_code" spellcheck="false" onclick="this.select()" style="opacity: 1;">

   <iframe frameborder="0" width="480" height="270" src="http://www.dailymotion.com/embed/video/x18adty"></iframe>

</textarea>

您是否试图在文本区域中将iframe显示为文本?如果是这样,html将其转义(最重要的是转换
),我正试图复制这个dailymotion.com/embed/video/x18adty“>,以便在我的表单文本框中显示它
    HtmlDocument doc = webBrowser1.Document;
    textBox5.Text = doc.GetElementById("video_title").InnerText;
    HtmlElement body = doc.GetElementById("embed_code");
    textBox3.Text = body.GetElementsByTagName("iframe").ToString();