Results 1 to 2 of 2

Thread: VB - Get HTML Source

Threaded View

  1. #1

    Thread Starter
    Junior Member Bean's Avatar
    Join Date
    Apr 2003
    Location
    GA, USA
    Posts
    23

    VB - Get HTML Source

    I saw a post where someone was looking for a way to grab the HTML source from a website, but I can't find that post to reply, so here's my snippet...(you need a from with an INET control on it)

    Code:
    Private Function GetHTML(url$) As String
    Dim response$
    Dim vData As Variant
    
      Inet1.Cancel
       response = Inet1.OpenURL(url)
      If response <> "" Then
        Do
          vData = Inet1.GetChunk(1024, icString)
          DoEvents
          If Len(vData) Then
            response = response & vData
          End If
        Loop While Len(vData)
      End If
       GetHTML = response
    End Function
    Last edited by Bean; Apr 3rd, 2003 at 02:19 PM.
    Is an IF...MAYBE...THEN... clause TRUE half of the time?

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