Get a full computer name or domain in C#
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/804700/how-to-find-fqdn-of-local-machine-in-c-net">How to find FQDN of local machine in C#/.NET ?</a>  </p>
</blockquote>



<p>Is there a way to get a full computer name or domain in C# Windows Application?</p>

<p>For example,</p>

<ul>
<li>Computer name : MYPC </li>
<li>Domain : LONDON.SYS.SAMPLE.COM</li>
<li>Full computer name : MYPC.LONDON.SYS.SAMPLE.COM</li>
</ul>

<p>I know that there are many ways to get computer name :</p>

<ul>
<li>Console.WriteLine(Environment.MachineName);</li>
<li>Console.WriteLine(System.Net.Dns.GetHostName());</li>
<li>Console.WriteLine(System.Windows.Forms.SystemInformation.ComputerName);</li>
<li>Console.WriteLine(System.Environment.GetEnvironmentVariable("COMPUTERNAME"));</li>
</ul>

<p>But, is it possible to get a full computer name or domain that a single computer is a member?</p>
