1

I am trying to create a smart search folder that only searches for items contained within specified folders. I have tried using the "Document Container" attribute, but I can't figure out how to use it correctly. Can someone walk me through an example of creating this kind of smart search?

  • Just navigate to the desired folder before creating the smart folder - or are you wanting to combine a group of searches? – red_menace Nov 6 '19 at 22:47
  • Yes, I would like to include several folders and also have the ability to exclude folders. How do I do that? – Peter Schorn Nov 8 '19 at 0:03
  • @red_menace , I am aware that if you navigate to a folder and then create a smart folder, you can choose to only search within that folder; however, I would like to search multiple folders and exclude folders. Ankii, I looked at all of those links you attached, and, unfortunately, none of them answered my question. Do you know how to do this? – Peter Schorn Nov 8 '19 at 2:36
  • As indicated in the previous links, there isn't a way to specify search folders in the Finder's Smart Folder query, so you would need to use a shell utility such as find or use something like NSMetadataQuery from a Cocoa app or script. You wouldn't be able to use the Finder for the results, though. – red_menace Nov 8 '19 at 2:56

You must log in to answer this question.

Browse other questions tagged .