VS 2010 How to read this image???? Please.....-VBForums
Results 1 to 6 of 6

Thread: How to read this image???? Please.....

  1. #1

    Thread Starter
    Member
    Join Date
    Aug 2006
    Posts
    53

    Question How to read this image???? Please.....

    hi.. vb forumers...
    i have a problem...
    this my Code:

    Code:
    Imports System.Web
    Imports mshtml
    
    Public Class Form1
    
        Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
            WebBrowser1.Navigate("http://buxp.org/login.php")
        End Sub
    
        Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
            WebBrowser1.Document.GetElementById("username").SetAttribute("value", TextBox1.Text)
            WebBrowser1.Document.GetElementById("password").SetAttribute("value", TextBox2.Text)
    
            WebBrowser1.Document.GetElementById("loginsubmit").InvokeMember("click")
        End Sub
    
        Private Sub WebBrowser1_DocumentCompleted(ByVal sender As System.Object, ByVal e As System.Windows.Forms.WebBrowserDocumentCompletedEventArgs) Handles WebBrowser1.DocumentCompleted
            Dim doc As IHTMLDocument2 = WebBrowser1.Document.DomDocument
            Dim imgRange As IHTMLControlRange = CType(doc.body, HTMLBody).createControlRange
            For Each img As IHTMLImgElement In doc.images
                If img.GetAttribute("src").ToString.Contains("image.php") Then
                    imgRange.add(img)
                    imgRange.execCommand("Copy", False, Nothing)
                    PictureBox1.Image = Clipboard.GetDataObject.GetData(DataFormats.Bitmap)
                    Exit For
                End If
            Next
        End Sub
    
    End Class
    and this a form preview


    and my question, what the code for write the image values to the textbox??

    thanks b4
    Attached Images Attached Images  

  2. #2

    Thread Starter
    Member
    Join Date
    Aug 2006
    Posts
    53

    Re: How to read this image???? Please.....

    bumb.............

  3. #3
    Frenzied Member
    Join Date
    Nov 2010
    Posts
    1,197

    Re: How to read this image???? Please.....

    whether you can get to the image or not the chances are its a picture and you will need to work out how to parse the pixels into characters not so simple!

    here to talk

  4. #4
    Bad man! ident's Avatar
    Join Date
    Mar 2009
    Location
    Cambridge
    Posts
    4,126

    Re: How to read this image???? Please.....

    Trying to bypass a captcha i very much doubt is allowed to be discussed here.

  5. #5
    Frenzied Member i00's Avatar
    Join Date
    Mar 2002
    Location
    1/2 way accross the galaxy.. and then some
    Posts
    1,846

    Re: How to read this image???? Please.....

    Quote Originally Posted by ident View Post
    Trying to bypass a captcha i very much doubt is allowed to be discussed here.
    Look up OCR on codeproject?

    Kris

  6. #6
    PowerPoster formlesstree4's Avatar
    Join Date
    Jun 2008
    Location
    On the Internet
    Posts
    3,249

    Re: How to read this image???? Please.....

    Yes, but, I think the OP wants to auto-fill in the captcha, which I'm pretty sure is not such a good idea.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Featured


Click Here to Expand Forum to Full Width

Survey posted by VBForums.