# Ability to create collection of all folders that contain a specific file type

**URL:** <https://resource.dopus.com/t/ability-to-create-collection-of-all-folders-that-contain-a-specific-file-type/39567>\
**Category:** Help & Support\
**Created:** [October 13, 2021, 5:22am UTC](https://resource.dopus.com/t/ability-to-create-collection-of-all-folders-that-contain-a-specific-file-type/39567 "2021-10-13T05:22:46Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Leo](https://resource.dopus.com/user_avatar/resource.dopus.com/leo/32/69732_2.png) [@Leo](https://resource.dopus.com/u/Leo)\
**Post date:** [October 13, 2021, 8:34am UTC](https://resource.dopus.com/t/ability-to-create-collection-of-all-folders-that-contain-a-specific-file-type/39567/2 "2021-10-13T08:34:34Z")

</div>

The way to do it is via a script column which indicates if a folder has the type of file you're interested in, and then filter on that column.

There's a script already written here where you'd just need to edit the wildcard at the top:

> [@Find folders that do not have a specific file?](https://resource.dopus.com/t/find-folders-that-do-not-have-a-specific-file/28558/12):
>
> Easy enough: [HasFolderJpeg.js.txt](https://resource.dopus.com/uploads/short-url/1BRIm436uDFOjzOpzfuuc653JG8.txt) (1.4 KB) // This is a script for Directory Opus. // See https://www.gpsoft.com.au/DScripts/redirect.asp?page=scripts for development information. var wild = DOpus.FSUtil.NewWild("\*.(jpg|jpeg)", "f"); // Called b…

Instructions on how to use the script are in this earlier post in the same thread (which has a slightly different script for finding something else):

> [@Find folders that do not have a specific file?](https://resource.dopus.com/t/find-folders-that-do-not-have-a-specific-file/28558/4):
>
> Download this and drop it into the list in Preferences / Toolbars / Scripts: [HasFolderArt.js.txt](https://resource.dopus.com/uploads/default/original/3X/b/f/bf76a69bce6c0f90edd5c3b2464ace954c363b8c.txt) (1.2 KB) (For more detail on installing it: [How to use buttons and scripts from this forum](https://resource.dopus.com/t/how-to-use-buttons-and-scripts-from-this-forum/3546/2) ) You can then use it like this: …

---

_[View the full topic](https://resource.dopus.com/t/ability-to-create-collection-of-all-folders-that-contain-a-specific-file-type/39567)._
