Results 1 to 4 of 4

Thread: Follow hyperlink in WebBrowser

  1. #1
    Guest
    Hi,

    When I try to follow the link of a web page:
    string = "http://jump.altavista.com/rs.go?Sony+digital+camera&pg=q&qe"
    b = inet1.openurl(string)

    I get "string" from the hyperlink property of the link.
    But when I try to run the program it says that the URL is malformed.

    Does anyone know why?


  2. #2
    Fanatic Member
    Join Date
    Feb 2000
    Location
    The Netherlands
    Posts
    715
    Don't use string as a variable name.

  3. #3
    Guest
    Actually I didn't use string as variable name, I used
    a as the variable name for the string.

    Funny thing is that when I call webbrowser1.navigate a, it works, but when i use inet.openurl(a) it won't - uRL is malformed.

  4. #4
    Guest
    Try this:

    Code:
    Private Sub Command1_Click()
    theURL = Inet1.OpenURL("http://jump.altavista.com/rs.go?Sony+digital+camera&pg=q&qe", icString)
    ReturnStr = Inet1.GetChunk(2048, icString)
    Do While Len(ReturnStr) <> 0
        DoEvents
        theURL = theURL & ReturnStr
        ReturnStr = Inet1.GetChunk(2048, icString)
    Loop
    End Sub

Posting Permissions

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



Click Here to Expand Forum to Full Width