title: Getting HTML from a page behind a login
body: <p>This question is a follow up to my <a href="https://stackoverflow.com/questions/56279/export-aspx-to-html">previous question</a> about getting the HTML from an ASPX page. I decided to try using the webclient object, but the problem is that I get the login page's HTML because login is required. I tried "logging in" using the webclient object:</p>
  
  <pre><code>WebClient ww = new WebClient();
  
   ww.DownloadString("Login.aspx?UserName=&amp;Password=");
  
   string html = ww.DownloadString("Internal.aspx");
  </code></pre>
  
  <p>But I still get the login page all the time. I know that the username info is not stored in a cookie. I must be doing something wrong or leaving out an important part. Does anyone know what it could be?</p>