VB.Net by API/System.Net/IPAddress
Версия от 16:40, 26 мая 2010; (обсуждение)
IPAddress.Equals
Imports System.Net
Public Class Tester
Public Shared Sub Main
Dim ipAddr1 As IPAddress = IPAddress.Parse("192.168.1.100")
Dim ipAddr2 As IPAddress = IPAddress.Parse("192.168.1.100")
If ipAddr1.Equals(ipAddr2) Then
Console.WriteLine("equal")
Else
Console.WriteLine("different")
End If
End Sub
End Class
IPAddress.Parse
Imports System.Net
Public Class Tester
Public Shared Sub Main
Dim ipAddr1 As IPAddress = IPAddress.Parse("192.168.1.100")
Dim ipAddr2 As IPAddress = IPAddress.Parse("192.168.1.100")
If ipAddr1.Equals(ipAddr2) Then
Console.WriteLine("equal")
Else
Console.WriteLine("different")
End If
End Sub
End Class