System.Net.ServicePointManager.Expect100Continue = false;
HttpWebRequest myRequest =
(HttpWebRequest)WebRequest.Create("http://en.wikipedia.org/w/api.php?action=query&titles=Car");
using (HttpWebResponse response = (HttpWebResponse)myRequest.GetResponse())
{
string ResponseText;
using (StreamReader reader = new StreamReader(response.GetResponseStream()))
{
ResponseText = reader.ReadToEnd();
}
SearchString.Text = ResponseText;
}
and the error is
The remote server returned error 403.

Posted May 16, 2011, 12:44 AM EDT
Fixing 403 errors - CheckUpDown
Suthish NairRank #92 · 22.8K reputationPosted May 16, 2011, 2:59 AM EDT
Sam HobbsRank #108 · 20.5K reputationPosted May 16, 2011, 9:14 PM EDT