HTTrack Website Copier
Free software offline browser - FORUM
Subject: Re: WINHHTrack vs command line version
Author: eliza sahoo
Date: 05/11/2010 10:22
 
Sometimes we may need to get the HTML contents of a web page programmatically
and without loading it in a browser. The following code can be used for doing
it. LetÂ’s take a look..
Private Function ReturnWebData(ByVal URL As String) As String
        Dim WebResltStr As String = Nothing
        Dim DtStrm As Stream = Nothing
        Dim StrmRdr As StreamReader = Nothing

        Dim WebReqst As WebRequest = Nothing
        Dim WebResp As HttpWebResponse = Nothing

        Try
            'Create the web request
            WebReqst = WebRequest.Create(URL)
            WebReqst.Credentials = CredentialCache.DefaultCredentials 

            'Get the response
            WebResp = DirectCast(WebReqst.GetResponse(), HttpWebResponse)

<http://www.mindfiresolutions.com/Retrieve-the-resulting-HTML-data-from-a-webpage-493.php>
 
Reply Create subthread


All articles

Subject Author Date
WINHHTrack vs command line version

05/28/2003 14:27
Re: WINHHTrack vs command line version

05/28/2003 18:40
Re: WINHHTrack vs command line version

05/29/2003 12:06
WINHHTrack command line version

11/18/2003 07:26
Re: WINHHTrack vs command line version

05/11/2010 10:22




b

Created with FORUM 2.0.11