Hello,
In a simple thread I have a code like the one below:
public void ProtectionRun()
{
while(true)
{
//Sleep thread for one minute
//Thread.Sleep(60 000);
HttpWebRequest
wReq=(HttpWebRe quest)WebReques t.Create("http://pipa.inov.pt/cgi-bin/camera");
HttpWebResponse wRes=(HttpWebRe sponse)wReq.Get Response();
MessageBox.Show ("Completed..." );
}
}
The problem is: "It only completes 2 times...". Why doesn't it get
completed all the times I want... and why does it hangs (on the thread
of course) in GetResponse() method?
The strange thing is that when I try to access any of the wRes
properties it doesn't complete nothing at all. More: it doesn't give
any exceptions... nothing... it seems like the function evaporates to
nowhere.
Tried with different websites and all give the same problem... hangs up
at the 3rd time. I'm not seeing the complete message for the third time
in all types of webpages (static .html; .asp; etc...)
Thanks for any help,
Nuno Magalhaes.