title: How to get the output of a powershell command into an array
body: <p>I am trying to get the output of a powershell command into an array, but it seems not to work. In fact I want to address the output with a row and a column index.
  e.g.</p>
  
  <pre><code>$a=Get-Service
  </code></pre>
  
  <p>With output (part)</p>
  
  <pre><code>Status   Name               DisplayName                           
  ------   ----               -----------                           
  Stopped  AeLookupSvc        Application Experience                
  Stopped  ALG                Application Layer Gateway Service     
  Stopped  AppIDSvc           Application Identity                  
  Running  Appinfo            Application Information               
  Stopped  AppMgmt            Application Management    
  </code></pre>
  
  <p>I want to address for the second line the DisplayName, e.g.</p>
  
  <pre><code>$a[2][2]
  </code></pre>
  
  <p>And it should give then </p>
  
  <pre><code>Application Layer Gateway Service
  </code></pre>
  
  <p>But this does not seem to work.</p>
  
  <p>Can anybody help?</p>