If I want to search for all the text files on my desktop but not the subdirectories on the desktop how would I do that?
To search just the desktop is easy enough. I'd just type "txt \desk" and without even finishing the word I'd be good. But yeah, that includes all the other stuff which I don't want.
If there's no way to exclude all subdirectories is there a way to just exclude one of them, ie the one which has the most irrelevant results? If for example there's a directory called books on my Desktop and I just wanted to exclude that, how would I do that?
Thanks!
how to search a directory without looking at subdirectories?
Re: how to search a directory without looking at subdirectories?
Please try the parent: search function:
parent:c:\users\<user>\desktop
replace <user> with your username.
or, search under \desk with no subdirectories:
\desk !*\desk*\*\*
or, search under \desk, but exclude \books
\desk !\books
parent:c:\users\<user>\desktop
replace <user> with your username.
or, search under \desk with no subdirectories:
\desk !*\desk*\*\*
or, search under \desk, but exclude \books
\desk !\books
Re: how to search a directory without looking at subdirectories?
thanks!
the parent function gives 0 hits, even after i replace the 'user' with my name. but the rest work fine, thank you!
what was supposed to happen with the parent function?
the parent function gives 0 hits, even after i replace the 'user' with my name. but the rest work fine, thank you!
what was supposed to happen with the parent function?
Re: how to search a directory without looking at subdirectories?
parent:<path> will limit the search to the specified path with no subfolders.
does parent:c:\users list any results?
If there is spaces in your username, please make sure you escape them with double quotes, for example:
parent:"c:\users\my user name\desktop"
does parent:c:\users list any results?
If there is spaces in your username, please make sure you escape them with double quotes, for example:
parent:"c:\users\my user name\desktop"
Re: how to search a directory without looking at subdirectories?
thanks for this
no, typing "parent:c:\users" without the quotes gives 0 results.
no, typing "parent:c:\users" without the quotes gives 0 results.
Re: how to search a directory without looking at subdirectories?
Please try with the quotes after parent:
eg:
parent:"c:\users"
eg:
parent:"c:\users"
Re: how to search a directory without looking at subdirectories?
Please try with the quotes after parent:
eg:
parent:"c:\users"
so sorry just seeing this now somehow hahah
i tried that. didn't work either
parent:"c:\users\BigDan\desktop" xls
Btw earlier I was given this command:
which worked pretty well. The issue with that is that I also see certain files that are on the H drive desktop. And I also saw files in the folder\desk !*\desk*\*\* xls
C:\Old Computer\Desktop which is the wrong folder.
These aren't big deals by any means. But is there a way to restrict to C:\users\ (any option here) \ Desktop ? I was hoping I could type
C:\users\*\Desktop but for some reason that didnt work.
Re: how to search a directory without looking at subdirectories?
btw, you didn't answer @void's question
does parent:c:\users list any results?
Try this
but for this to work, we have to enable "Expand Environment Variables" [Edit: idk if its enabled by default or not]
does parent:c:\users list any results?
Try this
Code: Select all
parent:"%userprofile%\Desktop" xls
Re: how to search a directory without looking at subdirectories?
Are you on a company computer?
Most companies have group policies in place for folder redirection (like the desktop folder).
What folder path do you see when you search for?
Most companies have group policies in place for folder redirection (like the desktop folder).
What folder path do you see when you search for
shell:desktop