Tuesday, September 01, 2009 1:12 PM
Filtering for files in Windows Explorer was introduced in Windows Vista but is gone from Windows 7. Now we are supposed to use Windows Search box to build a query and use it instead of filtering. My question is how to search or filter by files attributes. Say I want to see only Hidden files in my folder or exclude files marked as archived.
I've checked the following two guides. There are quite a lot of properties we can filter by. But attributes are not among them.
Thanks in advance.
Tuesday, November 10, 2009 4:09 AMI'm trying to figure out how to do this too. Anyone figure it out? Can it be done?
Monday, July 05, 2010 9:28 AM
In Windows Search type: 'attributes:' without the quotes, and wait one second; you should now see a list of attributes you can choose from. Just figured this out by trial and error.
Thursday, October 07, 2010 7:54 PM
Someone mentioned below that there's a popup displaying the attributes list but didn't spell out what those values were, so I'm going to go the extra step just in case that list isn't populating for you and so future web searches can actually show the values:
attributes:16 is D
attributes:32 is A
attributes:33 is RA
attributes:34 is HA
I'm sure there are others, but that popup seems to only give you the attributes that are present among the files that are in the dir you're searching so this list is incomplete. It would be nice if it was provided on the web somewhere - a good place would've been among those syntax links above.
- Marked As Answer by PronichkinMicrosoft Employee Thursday, October 07, 2010 8:53 PM
Wednesday, September 21, 2011 6:43 PM
It seems to be a bits sequence.
FILE_ATTRIBUTE_READONLY = 1
FILE_ATTRIBUTE_HIDDEN = 2
FILE_ATTRIBUTE_SYSTEM = 4
FILE_ATTRIBUTE_DIRECTORY = 16
FILE_ATTRIBUTE_ARCHIVE = 32
FILE_ATTRIBUTE_ENCRYPTED = 64
FILE_ATTRIBUTE_NORMAL = 128
FILE_ATTRIBUTE_TEMPORARY = 256
FILE_ATTRIBUTE_SPARSE_FILE = 512
FILE_ATTRIBUTE_REPARSE_POINT = 1024
FILE_ATTRIBUTE_COMPRESSED = 2048
FILE_ATTRIBUTE_OFFLINE = 4096
FILE_ATTRIBUTE_NOT_CONTENT_INDEXED = 8192
More info: http://ss64.com/nt/attrib.html
You can mix the values.
You can also use the letters, for example: attributes:RH
Friday, October 07, 2011 1:56 PMI have been trying out the information on this page, but didn't get it working. I would like to add some information, based on Windows 7 Ultimate 64 bits, about what works for me at the moment. But I am also still figuring out the whole picture. I needed to find the non-encrypted files in a folder structure of mostly encrypted folders and files, on a non-indexed external usb drive. Attributes:E or Attributes:AE did not work. I accidentily got some clues from Windows 7 by searching in an indexed folder. Typing in 'Attributes:' resulted in Windows 7 showing the attribute combinations that were present in the current folder and subfolders. By compressing a test file in an search indexed folder, windows showed me that the search filter was 'Attributes:16416'. Now 16416 decimal corresponds to X4020 hex, which is a combination of X40 and X20 (64 for 'encrypted' and 32 for 'archive'). Is that a coincidence? I was not able to construct other combinations that worked... Anyhow, my tip is: try this out on a controlled situation in an search indexed folder, and than use it in a non-indexed folder where necessary. I hope this is of use to anybody.
Thursday, June 21, 2012 12:49 AM
Note, 2nd link now goes to Win XP download page.
Unless using in porgramming, may also want to add these to your list:
MSDN Article about Advanced Query Syntax (AQS)
MSDN Windows Search Overview article: