Is there something I can do to test/poll a website to see if it is running from c# (or even vb)?
Poll a website
1 Answer
Know the answer? Post it. Somebody with the same question will find it here.
Is there something I can do to test/poll a website to see if it is running from c# (or even vb)?
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Puran KaushalRank #2,456 · 573 reputationPosted Jun 10, 2008, 4:56 AM EDT
Make Web Request to particular URL
using System.Net;
using System.IO;
HttpWebRequest myRequest = (HttpWebRequest)WebRequest.Create(URL);
myRequest.Method = "GET";
WebResponse myResponse = myRequest.GetResponse();
StreamReader sr = new StreamReader(myResponse.GetResponseStream(), System.Text.Encoding.UTF8);
string result = sr.ReadToEnd();
sr.Close();
myResponse.Close();