GetLocalHostIpAddresses – Retrieving the array of IP addresses for the local host

' Return the array of IP addresses for the local host' Note: Requires Imports System.Net' Example:'   Dim ipa As IPAddress'   For Each ipa In GetLocalHostIpAddresses()'      Debug.WriteLine(ipa.ToString())'   NextFunction GetLocalHostIpAddresses() As IPAddress()    Dim iphe As IPHostEntry = Dns.GetHostByName(Dns.GetHostName())    Return iphe.AddressList()End Function

Share the Post:
Share on facebook
Share on twitter
Share on linkedin

Overview

Recent Articles: