title: Trouble with powershell commas
body: <p>Im trying to write a very brief powershell script that runs a few commands, pipes their output to a text file, and then does a search against a keyword.</p>
  
  <p>I cant figure out what to change however for this line:</p>
  
  <pre><code>wmic service get name, startname | out-File "$pwd\admin\wmic.txt"
  
  WMIC.exe : Invalid GET Expression.
  At \\test.ps1:7 char:5
  + wmic &lt;&lt;&lt;&lt;  service get name startname | out-File "$pwd\admin\wmic.txt"
  + CategoryInfo          : NotSpecified: (Invalid GET Expression.:String) [], RemoteException
  + FullyQualifiedErrorId : NativeCommandError
  </code></pre>
  
  <p>I believe the error is generated from the ',' as powershell uses the comma to create an array.
  Any thoughts or suggestions?</p>
  
  <p>Thanks</p>