WebException , the remote name could not be resolved

Rate It (1)

Last post 10-08-2009 1:19 AM by vsurana. 5 replies.

Sort Posts:

  • WebException , the remote name could not be resolved

    05-22-2006, 6:11 AM
    • Member
      80 point Member
    • irfanzafar
    • Member since 08-20-2004, 9:28 AM
    • Posts 16
    I am working on  Smart Device Application, using web services in it.
    I am able to connect with web service, but when the response comes from the method that is called, i.e. dataset is returned. it throw this exception

    WebException , the remote name could not be resolved

    if i test it on local machine, it works fine. but if i use web service from a remote PC, i got this exception.
    I have gone to many websites, each talking about this error, but i am not able to find any solution.....
    Please advice on this issue..

    Regards
    Irfan Zafar
  • Re: WebException , the remote name could not be resolved

    05-29-2006, 2:42 AM
    • Member
      230 point Member
    • zarehman
    • Member since 09-28-2004, 1:28 AM
    • Lahore, Pakistan
    • Posts 49
     Hi Could you please go little deeper into the exception details by checking the innerException messages by using following code.

    Try
        ' some code that is susceptible to throw exception.
    Catch ex As Exception
        Response.Write(ex.Message)
        While Not ex.InnerException Is Nothing
              Response.Write(ex.InnerException.Message)
              ex = ex.InnerException
        End While
    End Try


    It would be giving u the detail description of what might be the problem.Also check that there might be some problem in connecting to remote server as exception implies "
    WebException , the remote name could not be resolved".

    Regards.

    ZIA UR REHMAN
  • Re: WebException , the remote name could not be resolved

    05-29-2006, 2:54 AM
    • Member
      230 point Member
    • zarehman
    • Member since 09-28-2004, 1:28 AM
    • Lahore, Pakistan
    • Posts 49
    Also please check this link out Bridging to External Web Services. I hope it would be helping you in this case.

    Regards.

    ZIA UR REHMAN
  • Re: WebException , the remote name could not be resolved

    02-13-2008, 7:12 AM
    • Member
      2 point Member
    • Tarun Prabhu
    • Member since 02-13-2008, 12:08 PM
    • Posts 1

    Better late than never, I suppose. I had the same problem and I stumbled across this post. This is hoping others find it useful.

    Check if you have to use a proxy server to access external URLs. In that case, add the following to web.config

    <system.net>

        <defaultProxy>

            <proxy usessystemdefault="False" proxyaddress="http://your-proxy-name.domain.com:port-number-if-any" bypassonlocal="True" autoDetect="False" />


        </defaultProxy> 

    </system.net>
     

    I had a similar problem and this worked for me. Smile 

  • Re: WebException , the remote name could not be resolved

    09-04-2008, 6:38 PM
    • Member
      276 point Member
    • aarnott
    • Member since 05-13-2003, 4:18 PM
    • Kirkland, WA
    • Posts 54

    Like magic, Tarun.  Thanks for the tip.

    Andrew L Arnott
    Visual Studio Platform & Ecosystem
  • Re: WebException , the remote name could not be resolved

    10-08-2009, 1:19 AM
    • Member
      28 point Member
    • vsurana
    • Member since 06-10-2008, 1:46 PM
    • Posts 24

    I had a similar problem and this worked for me. My error was i have set bypassonlocal="true" Case Problem it should be bypassonlocal="True" Thanks

Page 1 of 1 (6 items)