Jump to content
Xtreme .Net Talk

neoryudo

Members
  • Posts

    2
  • Joined

  • Last visited

About neoryudo

  • Birthday 04/15/1991

neoryudo's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Yeah I didn't mean to "ping the port " bit through a port number, website allow you to connect to them through port 80 and online games allow you to connect to the servers through for example port 4500, now if the servers are down for some reason they will close off port 4500 to stop people connecting to the server, but my code doesn't ping through any port so even of the game servers are offline for users, my code is still saying they are online because it is not trying to ping through the closed port? Do you understand where I am coming from?
  2. ok so i am really sorry if this has been answered before i am not the best at at VB.net by far anyways i have a problem, i have written some code in a VB i have made that pings a server and give me and MS and writes it on the app, now what i need is it to be able to ping the port in the same equation but i am not sure how and if i can even implement it into my code, the reason behind this is that it pings a game server, so when the servers are not up they close a port, anyways i will put some code here and see if you guys think i can implement it if not any pointers will be greatly appreciated If InternetConnection() = True Then Dim p As System.Net.NetworkInformation.Ping = New System.Net.NetworkInformation.Ping Dim prep As System.Net.NetworkInformation.PingReply 'if server = 0 then ping server and If (server = 0) Then Dim url As String = "79.110.94.195" prep = p.Send(url) If (prep.Status = System.Net.NetworkInformation.IPStatus.Success) Then Dim address As String = prep.Address.ToString Dim time As String = prep.RoundtripTime.ToString Label3.Text = (time + " Ms") server_pic.Image = Image.FromFile("config\server_up.png") Else Dim status As String = prep.Status.ToString server_pic.Image = Image.FromFile("config\server_down.png") Label3.Text = ("0 Ms") End If
×
×
  • Create New...