title: Proxy authentication required error when using a webservice
body: <p>I've a .Net 4.0 windows application running on Windows 7 and Windows XP.
  One of the modules in the app connects to a url on the internet[say http://abc.com/xyz/MyWebService] using their web service.This functionality has been working until last week when I started to get this error message when invoking a method on the webservice</p>
  
  <blockquote>
    <p>There was no endpoint listening at <a href="http://abc.com/xyz/MyWebService" rel="nofollow">http://abc.com/xyz/MyWebService</a>
    that could accept the message. This is often caused by an incorrect
    address or SOAP action. See InnerException, if present, for more
    details.And the InnerException was:HTTP Error 407 Proxy authentication required</p>
  </blockquote>
  
  <p>I re-ran this code[on Windows 7] multiple times and I found out that this behavior is random...ie.sometimes am able to invoke webservice method on the server without any error.</p>
  
  <p>Not sure whats going on behind the scenes and what could explain this random behavior.
  Also, this error does not come on a machine which has Windows XP that is located in a different geographical location on the company intranet.</p>
  
  <p>Any ideas?</p>
  
  <p>Note:When I added following node in my app.config, the error seems to have gone:</p>
  
  <pre><code>&lt;system.net&gt;
      &lt;defaultProxy enabled="true" useDefaultCredentials="true"&gt;
      &lt;/defaultProxy&gt;
  &lt;/system.net&gt;
  </code></pre>