# Output iterator

**URL:** https://www.finalbuilder.com/forums/t/output-iterator/3856
**Category:** Feature Requests
**Created:** [May 23, 2007, 9:27am UTC](https://www.finalbuilder.com/forums/t/output-iterator/3856 "2007-05-23T09:27:56Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![stevage](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/s/bc8723/32.png) [@stevage](https://www.finalbuilder.com/forums/u/stevage)
#### Post date: [May 23, 2007, 9:27am UTC](https://www.finalbuilder.com/forums/t/output-iterator/3856/1 "2007-05-23T09:27:56Z")

</div>

Ever thought of an "output iterator"? It would start by executing a program of some type, then iterating over each line of output. It would make it easy to have a very simple filter. For example today I wanted to filter out the output of the "dir /s" command, ditching any line with "(DIR)", "File(s)", or a blank line.  
  
Of course, I could achieve the same result by writing the result to one file, then doing a file contents iterator to write it to another&nbsp; file, then delete the original. But not as elegant or cute, eh? 🙂  
  
Steve

---

<div class="post-metadata">

### Author: ![tate](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/t/e19b73/32.png) [@tate](https://www.finalbuilder.com/forums/u/tate)
#### Post date: [May 23, 2007, 9:33am UTC](https://www.finalbuilder.com/forums/t/output-iterator/3856/2 "2007-05-23T09:33:06Z")

</div>

what about using a List Iterator? You could set the Log to Variable to a variable, and then use that variable in the List Iterator action. It’s not as elegant as an action that does the whole thing, but is better than writing to a file and then reading it back in 🙂  
  
.t8

---

<div class="post-metadata">

### Author: ![stevage](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/s/bc8723/32.png) [@stevage](https://www.finalbuilder.com/forums/u/stevage)
#### Post date: [May 24, 2007, 6:04am UTC](https://www.finalbuilder.com/forums/t/output-iterator/3856/3 "2007-05-24T06:04:17Z")

</div>

Hey, I didn’t know you could “Log to Variable”. That’s pretty nifty.  
  
Steve
