title: Run c# commands remotely
body: <p>I am new to C# and one of my intentions in my program is to know a remote machine system architecture.
  I found this command: </p>
  
  <pre><code>System.Environment.Is64BitOperatingSystem
  </code></pre>
  
  <p>that essentially gets the value of the environment property, but this only on the local machine i am developing from.</p>
  
  <p>Is there a way to run this commnad, or any other command remotely?</p>
  
  <p>Or, I know how to do that in PowerShell, by querying with Get-WMIObject with -ComputerName Parameter that gives my the option the query WMI remotely.
  So maybe there another simple way to do that also in C#?</p>
  
  <p>Thank you</p>
  
  <p>UPDATE:
  I used that link: <a href="https://docs.microsoft.com/en-us/windows/desktop/wmisdk/connecting-to-wmi-remotely-with-c-" rel="nofollow noreferrer">https://docs.microsoft.com/en-us/windows/desktop/wmisdk/connecting-to-wmi-remotely-with-c-</a> what Alex gave me, and in the article I need to use the assembly:</p>
  
  <pre><code>Microsoft.Management.Infrastructure
  </code></pre>
  
  <p>But I just can't reference it, or find it in my computer...
  The microsoft article doesn't say anything about that assembly where I can find it.</p>