I have an application which deals with the website flipcss.com .
For the "Or Paste CSS:" text I add text with the element id
WebBrowser1.Document.GetElementById("css_data").InnerText = TextBox1.Text
And to click the "Flip the CSS" button I use the code
WebBrowser1.Document.Forms(0).InvokeMember("submit")
But for the results or "generated" text, I cannot get it back to my application because it doesn't have an id.
The HTML inspector only has
<textarea class="form-control" name="css_data" rows="10" dir="LTR">
I want to bring the generated text back to another text box.
after some searching and editing i found it
For Each h As HtmlElement In WebBrowser1.Document.GetElementsByTagName("textarea")
If Not Object.ReferenceEquals(h.GetAttribute("dir"), Nothing) AndAlso h.GetAttribute("dir").Equals("LTR") Then
TextBox2.Text = h.InnerText
Exit For
End If
Next
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.