title: batch: ignore last line of an output
body: <p>I have a pretty basic script that echos local administrator accounts. My goal is to get rid of all of the header/footer information. </p>
  
  <p>So far I have:</p>
  
  <pre><code>FOR /F "skip=6" %%G IN ('net localgroup administrators')  DO echo %%G
  </code></pre>
  
  <p>Which echos:</p>
  
  <pre><code>Administrator
  MyName
  The
  </code></pre>
  
  <p>"The" being the first word in the footer: "The command completed successfully."</p>
  
  <p>So I'd like to get rid of "The" but I understand that I may have to restructure the entire script, which is fine. I have tried saving to a variable %str% but you can't set multi-line variables. Also, using a txt file as a buffer is not an option.</p>
  
  <p>Any input?</p>