G
Guest
I want to save in a file the HTML code generated by a WebRequest to an aspx page.
When a connect to a external site, i can obtain the html code generated by server. But when i connect to a page of my application, the server responds "(401) Non autorisé. "
the is:
WebRequest request=WebRequest.Create("http://localhost/software/tools/pages/index.htm");
WebResponse response=request.GetResponse();
Stream stream=response.GetResponseStream();
the error is on the "WebResponse response=request.GetResponse();" only if the page is an aspx page in my code but never on an external site ...
When a connect to a external site, i can obtain the html code generated by server. But when i connect to a page of my application, the server responds "(401) Non autorisé. "
the is:
WebRequest request=WebRequest.Create("http://localhost/software/tools/pages/index.htm");
WebResponse response=request.GetResponse();
Stream stream=response.GetResponseStream();
the error is on the "WebResponse response=request.GetResponse();" only if the page is an aspx page in my code but never on an external site ...