Walter.Net.Networking
DnsServers Method
Walter.Net.Networking Assembly > Walter.Net.Networking Namespace > LocalNetwork Class : DnsServers Method
Get the DNS servers for this network according to the network cards configurations.
Syntax
public static IReadOnlyList<IPAddress> DnsServers()

Return Value

list of IP addresses for the DNS servers
Remarks
Test the IP addresses to see if the IP address is local, LAN or WAN based to test if the list contains external DNS servers. Pay attention when in use with VPN servers as you may get DNS server's located outside your own domain when using multiple NIC's
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

LocalNetwork Class
LocalNetwork Members