ping an ip Address

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

    ping an ip Address

    Is it possible, without any 3rd party tools to simply ping an ip address,
    and get back if the ping was sucessfull.


    Thanks

  • Uli Netzer

    #2
    Re: ping an ip Address


    "Newbie" <newbie@nospam. comschrieb im Newsbeitrag
    news:ejwSokiGJH A.3640@TK2MSFTN GP04.phx.gbl...
    Is it possible, without any 3rd party tools to simply ping an ip address,
    and get back if the ping was sucessfull.
    >
    >
    Thanks

    Dim oPing As New Net.NetworkInfo rmation.Ping
    Dim myResponse As Net.NetworkInfo rmation.PingRep ly
    Dim myStatus As New clsStatus()

    Try

    myResponse = oPing.Send(txtC omputername.Tex t, 8)
    If myResponse.Stat us = NetworkInformat ion.IPStatus.Su ccess
    Then

    Catch exPing As Net.NetworkInfo rmation.PingExc eption
    'here the computer doesn't have a DHCP Lease anymore
    MessageBox.Show ("PC not online", "Ping", MessageBoxButto ns.OK,
    MessageBoxIcon. Information)

    Catch ex As Sockets.SocketE xception
    'here the computer is offline but still has a DHCP Lease
    MessageBox.Show ("PC not online", "Socket", MessageBoxButto ns.OK,
    MessageBoxIcon. Information)

    End Try

    Comment

    • rowe_newsgroups

      #3
      Re: ping an ip Address

      On Sep 19, 3:27 am, "Newbie" <new...@nospam. comwrote:
      Is it possible, without any 3rd party tools to simply ping an ip address,
      and get back if the ping was sucessfull.
      >
      Thanks
      Please open the object browser and search for "ping".

      Alternate:

      Please open google and search for "ping Visual Basic .NET"

      Thanks,

      Seth Rowe [MVP]

      Comment

      • =?Utf-8?B?S2VycnkgTW9vcm1hbg==?=

        #4
        RE: ping an ip Address

        Newbie,

        You can use Visual Basic's My.Computer.Net work.Ping method.

        Kerry Moorman


        "Newbie" wrote:
        Is it possible, without any 3rd party tools to simply ping an ip address,
        and get back if the ping was sucessfull.
        >
        >
        Thanks
        >
        >

        Comment

        • kimiraikkonen

          #5
          Re: ping an ip Address

          On Sep 19, 10:27 am, "Newbie" <new...@nospam. comwrote:
          Is it possible, without any 3rd party tools to simply ping an ip address,
          and get back if the ping was sucessfull.
          >
          Thanks
          As Kerry pointed out, you can use My.Computer.Net work.Ping method
          which returns a Boolean as True if pinging was successful.

          See more for usage:


          HTH,

          Onur Güzel

          Comment

          Working...