Is it a normal "http://server/" address?
Are you using IPSEC?
It's possible the tcp/ip registry settings could be corrupted...
http://support.microsoft.com/kb/811259
> Hi,
>
> I'm having a problem with asynchronous HttpWebRequest. It's a simple
> http client-server. For most of my users it works fine. However, some
> of them get the exception:
>
> System.Net.WebException: Unable to connect to the remote server --->
> System.Net.Sockets.SocketException: The attempted operation is not
> supported for the type of object referenced
> at System.Net.Sockets.Socket.get_ConnectEx()
> at System.Net.Sockets.Socket.BeginConnectEx(EndPoint remoteEP,
> Boolean flowContext, AsyncCallback callback, Object state)
> at System.Net.Sockets.Socket.UnsafeBeginConnect(EndPo int remoteEP,
> AsyncCallback callback, Object state)
> at System.Net.ServicePoint.ConnectSocketInternal(Bool ean
> connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress&
> address, ConnectSocketState state, IAsyncResult asyncResult, Int32
> timeout, Exception& exception)
> --- End of inner exception stack trace ---
> at System.Net.HttpWebRequest.EndGetResponse(IAsyncRes ult
> asyncResult)
> My code is:
>
> Uri url = new Uri(getURI());
> m_request = (HttpWebRequest)WebRequest.Create(url);
> m_request.Credentials = CredentialCache.DefaultCredentials;
> m_request.UserAgent = getUserAgent();
> m_request.BeginGetResponse(new AsyncCallback(ProcessResponse), null);
> and then:
>
> private void ProcessResponse(IAsyncResult asynchronousResult) {
> HttpWebResponse response =
> (HttpWebResponse)m_request.EndGetResponse(asynchro nousResult);
> Stream stream = response.GetResponseStream();
> ...
> }
> This is so weird.
> Any ideas ?
> Thanks!
>