Network Domain address / name

kasdoffe

Well-known member
Joined
Aug 27, 2003
Messages
57
Let me set this up (I may get the terminology wrong).

Machine Name: Kasdoffe
Domain Name: WS
User Name: Jeff
Full computer address: Kasdoffe.WhateverSystems.com

In code, I can figure out how to get the machine name, the domain, and the user. How do I get the full computer address, specifically the WhateverSystems.com part.

Thanks.
 
You want the DNS name? Where did you get the other info from? Well, if you have the IP, you can get the fullname by:

System.Net.IPHostEntry host = System.Net.Dns.GetHostByAddress(new System.Net.IPAddress(127001));
 
Back
Top