Status Codes of web pages
<p>I am trying to get the result out of a web page and to avoid web exceptions I want to check the status code before I request for the result from the stream. However:</p>

<pre><code>HttpWebResponse response = (HttpWebResponse)webRequest.GetResponse();
</code></pre>

<p>throws an exception when I try to get the error code after this using 
<code>response.StatusCode</code></p>

<p>Is there a way to avoid exceptions to get the <code>StatusCode</code>?</p>
