# File iterator search order

**URL:** https://www.finalbuilder.com/forums/t/file-iterator-search-order/3850
**Category:** Feature Requests
**Created:** [April 13, 2007, 7:12am UTC](https://www.finalbuilder.com/forums/t/file-iterator-search-order/3850 "2007-04-13T07:12:07Z")
**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: [April 13, 2007, 7:12am UTC](https://www.finalbuilder.com/forums/t/file-iterator-search-order/3850/1 "2007-04-13T07:12:07Z")

</div>

How about being able to specify the order in which files are iterated over? For example:  
- alphabetically  
- by date  
- by size  
  
Explanation: This would be useful to me at the moment as I’m building a list of completed builds, and I would like to default to the most recent build. Iterating by date would make that easy. (actually I’m using the Folder Iterator, but the principle is the same…)  
  
Steve

---

<div class="post-metadata">

### Author: ![angus](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/a/b3f665/32.png) [@angus](https://www.finalbuilder.com/forums/u/angus)
#### Post date: [April 16, 2007, 1:24am UTC](https://www.finalbuilder.com/forums/t/file-iterator-search-order/3850/2 "2007-04-16T01:24:53Z")

</div>

Hi Steve,  
  
We could probably look into a “Sort FileSet” action. Would that be useful enough?  
  
Regards,  
  
  
Angus

---

<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: [April 18, 2007, 5:09am UTC](https://www.finalbuilder.com/forums/t/file-iterator-search-order/3850/3 "2007-04-18T05:09:56Z")

</div>

Bleh, you know I don’t use filesets 🙂 Compare:  
  
File iterator (with sort parameter)  
-Do something based on file.  
  
Totally self-contained.  
  
Fileset define  
Fileset sort  
File iterator (on fileset)  
-Do something based on file  
  
Those three operations have to be in the correct order. The fileset is now defined forever, despite its having no meaning anywhere else in the project. Less elegant.  
  
But yeah, if that’s easier for you, I would use that and consider it a ‘workaround’. 🙂  
  
Steve
