|
-
Apr 28th, 2011, 11:49 AM
#1
Thread Starter
Member
I have two problems?
1. I am trying to click a multiple chose, and I am using this code for it.
Code:
WebBrowser1.Document.GetElementById("multi").SetAttribute("value", "yourownmulti")
Now this code chooses the multi chose button, and the problem is that when it clicks it, another box would appear, but this code is only choosing it, but not clicking it.
2. I have a textbox and a button, now when the button is pressed, it takes part of the source code from the html and put it in the textbox. Now the problem is that when it refreshes the page another pile of code is entered in the textbox and removes the other code. How can I make it to keep everything in, line by line?
The code I use is:
Code:
Dim elements() As HtmlElement = WebBrowser1.Document.GetElementsByTagName("a").Cast(Of HtmlElement).Where(Function(el As HtmlElement) el.GetAttribute("className") = "author").ToArray
Dim authors() As String = Array.ConvertAll(elements, Function(el) el.InnerText).Distinct.ToArray
TextBox1.Lines = authors
In short of the second question:
I want it to keep every code, line under a line or line by line, even when the page is refreshed and other codes are entered in the textbox
Thanks in advance
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|