IPInterfaceProperties::IsDynamicDnsEnabled Property

 

Gets a Boolean value that indicates whether this interface is configured to automatically register its IP address information with the Domain Name System (DNS).

Namespace:   System.Net.NetworkInformation
Assembly:  System (in System.dll)

public:
property bool IsDynamicDnsEnabled {
	virtual bool get() abstract;
}

Property Value

Type: System::Boolean

true if this interface is configured to automatically register a mapping between its dynamic IP address and static domain names; otherwise, false.

Dynamic DNS enables a client to inform the DNS servers that its dynamic IP address is mapped to its static host name.

The following code example displays the value of this property.

void DisplayDnsConfiguration()
{
   array<NetworkInterface^>^adapters = NetworkInterface::GetAllNetworkInterfaces();
   System::Collections::IEnumerator^ myEnum10 = adapters->GetEnumerator();
   while ( myEnum10->MoveNext() )
   {
      NetworkInterface ^ adapter = safe_cast<NetworkInterface ^>(myEnum10->Current);
      IPInterfaceProperties ^ properties = adapter->GetIPProperties();
      Console::WriteLine( adapter->Description );
      Console::WriteLine( "  DNS suffix................................. :{0}", 
         properties->DnsSuffix );
      Console::WriteLine( "  DNS enabled ............................. : {0}", 
         properties->IsDnsEnabled );
      Console::WriteLine( "  Dynamically configured DNS .............. : {0}", 
         properties->IsDynamicDnsEnabled );
   }
}

.NET Framework
Available since 2.0
Return to top
Show: