System.Net.HttpWebRequest req;
System.Net.HttpWebResponse res;
string url=" http://www.baidu.com";
req = (System.Net.HttpWebRequest)System.Net.WebRequest.Create(url);
res = (System.Net.HttpWebResponse)req.GetResponse();
System.IO.StreamReader strm = new System.IO.StreamReader(res.GetResponseStream(), Encoding.GetEncoding("gb2312"));
MessageBox.Show(strm.ReadToEnd());
System.Net.HttpWebResponse res;
string url=" http://www.baidu.com";
req = (System.Net.HttpWebRequest)System.Net.WebRequest.Create(url);
res = (System.Net.HttpWebResponse)req.GetResponse();
System.IO.StreamReader strm = new System.IO.StreamReader(res.GetResponseStream(), Encoding.GetEncoding("gb2312"));
MessageBox.Show(strm.ReadToEnd());