I want to get domain names from specific ip range with C#
IPAddress addr = IPAddress.Parse("100.10.100."+i);
entry = Dns.GetHostEntry(addr);
But I encountered this error The requested name is valid and was found in the database, but it does not have the correct associated data being resolved for
Some Ip hasn't domain names.But I can't null check GetHostEntry. I tried like that but nothing changed.I encountered same error
if(Dns.GetHostEntry(addr)!=null)
How can I make null check for bypass this error?