using System;
using System.Net;
using System.IO;
public class MainClass {
[STAThread]
public static void Main(string[] args)
{
string htmlUri = "http://www.navioo.com";
WebRequest requestHtml = WebRequest.Create(htmlUri);
WebResponse responseHtml = requestHtml.GetResponse();
// Read the text from the response stream.
using (StreamReader r = new StreamReader(responseHtml.GetResponseStream()))
{
Console.WriteLine( r.ReadToEnd());
}
}
}
Output
Java examples (example source code) Organized by topic
...
...