C# Dealing with webbrowser images help.

Posts 1–4 of 4 · Page 1 of 1
C# Dealing with webbrowser images help.
Code:
private void button1_Click(object sender, EventArgs e)
        {
            webBrowser1.Document.GetElementById("txtAccountId").SetAttribute("value", textBox1.Text);
That's how you set the value on a webbrowser for a textfield(We'll say a account ID) whenever your making a bot or whatever.
What I can't figure out, which I'll probably get flamed for it. Is how to convert a image, or not convert but display the image off of the webbrowser onto a picturebox.
Just using this as an example so you can understand what I'm saying more.
Nexon Passport Sign-Up
For example, How would I display the captcha onto a picturebox?
Thanks in Advance,
Caleb.
whats up with all newfags thinking they get flamed for posting random questions? o__O

Code:
HtmlElementCollection elementz = webBrowser1.Document.GetElementsByTagName("img");
asumin their using img ofcourse, dont know what other methods those webguys have to display pictures, then all you have to do it parse the stuff inside:

Code:
for (int i = 0; i < elementz.Count - 1; i++)
{
    if (elementz[i].InnerHtml.ToString().Contains("src"))
edit: figure the rest out yourself(like parsing src="whateverishere") and loading the picture
Quote Originally Posted by Hell_Demon View Post
whats up with all newfags thinking they get flamed for posting random questions? o__O
Hmmmm.... I wonder who could have caused them to think that.... ;l



But in all seriousness, what is this "img"/"src" stuff? Like where is it in the web page?
Not a new fag, other account just got banned. Been here since '08. I just know the people at MPGH. They flame. For no reason.
EDIT: at why06
Code:
HtmlElementCollection elementz = webBrowser1.Document.GetElementsByTagName("img");
If your talking about that, "img" is what the html document refers to the image by.
Posts 1–4 of 4 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Talk with us