Internet connection present?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • ultradiv

    #1

    Internet connection present?

    I have a partly produced VB.NET app that needs to 'know' when the client
    machine has an interent connection so that it can connect to a remote
    webservice.
    Any ideas?

    Thanks
    Andy


  • Cor Ligthert [MVP]

    #2
    Re: Internet connection present?

    Ultradiv,

    Yes set it in a try and catch block if it does not connect than there is no
    connection to that webservice.

    Cor

    "ultradiv" <andy@vpwd.nets chreef in bericht
    news:eawaKQ%23q GHA.516@TK2MSFT NGP05.phx.gbl.. .
    >I have a partly produced VB.NET app that needs to 'know' when the client
    machine has an interent connection so that it can connect to a remote
    webservice.
    Any ideas?
    >
    Thanks
    Andy
    >
    >

    Comment

    • ultradiv

      #3
      Re: Internet connection present?

      Thanks Cor.
      I'll do that
      Andy

      "Cor Ligthert [MVP]" <notmyfirstname @planet.nlwrote in message
      news:u$CqMU%23q GHA.4408@TK2MSF TNGP04.phx.gbl. ..
      Ultradiv,
      >
      Yes set it in a try and catch block if it does not connect than there is
      no
      connection to that webservice.
      >
      Cor
      >
      "ultradiv" <andy@vpwd.nets chreef in bericht
      news:eawaKQ%23q GHA.516@TK2MSFT NGP05.phx.gbl.. .
      I have a partly produced VB.NET app that needs to 'know' when the client
      machine has an interent connection so that it can connect to a remote
      webservice.
      Any ideas?

      Thanks
      Andy
      >
      >

      Comment

      • Larry Lard

        #4
        Re: Internet connection present?

        ultradiv wrote:
        I have a partly produced VB.NET app that needs to 'know' when the client
        machine has an interent connection so that it can connect to a remote
        webservice.
        Any ideas?
        In VB2005 you can use My.Computer.Net work.IsAvailabl e, but as the docs
        say that only tells you if "a computer is connected to *a* network". In
        the long run, with proxies and network topologies and firewalls and so
        on, the only sure way to tell if you can connect to a remote webservice
        is to Try is and see. I mean, Try it and Catch.


        --
        Larry Lard
        larrylard@googl email.com
        The address is real, but unread - please reply to the group
        For VB and C# questions - tell us which version

        Comment

        Working...