I\'m using the code below to pull one of our 3rd party developed pages in so I can parse it as XML for my random bits of work.
Irritatingly we stil have a browser de
Browser detection is done based on a header in the request to the server. All you need to do is set that header. However, with HttpWebRequest you don't set that through the headers collection but rather with the .UserAgent property.
...
System.Net.WebRequest objRequest =
System.Net.HttpWebRequest.Create(strURL);
//Pretend to be IE7
((System.Net.HttpWebRequest)objRequest).UserAgent =
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0)";
objResponse = objRequest.GetResponse();
...