What I would like to know is how I am supposed to capture response
errors from the server. For instance, If the server is requiring "Basic
Authentication" and I don't supply a password, I might get a response
from the server that looks like this:
<html><head><title>Error 401.2</title>
<meta name="robots" content="noindex">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html;
charset=iso-8859-1"></head>
<body>
<h2>HTTP Error 401</h2>
<p><strong>401.2 Unauthorized: Logon Failed due to server
configuration</strong></p>
<p>This error indicates that the credentials passed to the server do not
match the credentials required to log on to the server. This is usually
caused by not sending the proper WWW-Authenticate header field.</p>
<p>Please contact the Web server's administrator to verify that you have
permission to access to requested resource.</p>
</body></html>
How can I programmatically know that I received a logon failure. Am I
supposed to parse the above text or is there an easier way? Is there
a list of possible errors somewhere?
I'd appreciate your help,
Jerry J