title: powershell get-service -forgroundcolor
body: <p>I am trying to change the color of my get-service output. It does not seem to allow me to use the write-host -forgroundcolor parameter after get-service. Is there any way around this?</p>
  
  <p>I have tried the following configurations:</p>
  
  <pre><code>get-service write-host -foregroundcolor "green"
  get-service -foregroundcolor "green"
  </code></pre>
  
  <p>I can get it to kind of work if I save get-service into a variable and place write-host in front like so:</p>
  
  <pre><code>$var = get-service
  
  write-host $var -foregroundcolor "green"
  </code></pre>
  
  <p>The problem with this is the output is not formatted correct and becomes a single line. </p>