Help with Simple way to Retrieve HTML page

  • Thread starter Thread starter David Elliott
  • Start date Start date
D

David Elliott

I know I can use
AxSHDocVw.AxWebBrowser browser.Navigate(...);
catch the
browser_DocumentComplete()
and retrieve using the page using
htm = (mshtml.HTMLDocument)browser.Document;

I am looking for a non-GUI way to just retrieve the web page.
I know that there is, I just can't seem to find/remember what it is.

Thanks,
Dave
(e-mail address removed)
 
A response was addressed to me and I am posting the answer.

HttpWebRequest and HttpWebResponse

Cheers,
Dave
 
Hello,

David Elliott said:
I am looking for a non-GUI way to just retrieve the web page.
I know that there is, I just can't seem to find/remember what it is.

\\\
Imports System.IO
Imports System.Net
..
..
..
Dim wrq As WebRequest = _
WebRequest.Create( _
"http://stud3.tuwien.ac.at/~e0025861/index.html" _
)
Dim wrp As WebResponse = wrq.GetResponse()
Dim sr As StreamReader = _
New StreamReader(wrp.GetResponseStream())
MessageBox.Show(sr.ReadToEnd())
///

Regards,
Herfried K. Wagner
 
Back
Top