Link to home
Start Free TrialLog in
Avatar of rgb192
rgb192Flag for United States of America

asked on

capital .JPG

I want to search for all files using windows 7 file explorer that are .JPG (capital letters)
nothing else
not .jpg or .jpeg or JPEG

type:.JPG gets all the jpg files
Avatar of Ben Hart
Ben Hart
Flag of United States of America image

Hmm maybe searching ".JPG"
Avatar of ☠ MASQ ☠
☠ MASQ ☠

Windows 7 doesn't natively support case sensitive searching - you'll need a third party tool
XSearch is one of many that will do this for you for free
http://www.easexp.com/xsearch/
You can't pipe with findstr?
I was concentrating on Windows Explorer and the GUI

findstr does search using case but doesn't it look for text inside a file rather then the filename ??  (like grep)
dir *.jpg /s > %temp%\all.txt | findstr /i "JPG" %temp%\all.txt

this works

of course it's not exploder, but it works.
I've been using an excellent file manager called Total Commander for many years:
http://www.ghisler.com/

It allows a Regular Expression (RegEx) in a file name search, and that does what you want. The RegEx for it is:

(?-i)\.JPG

That is a case sensitive search for .JPG files. Likewise, here's the case sensitive search for .jpg files:

(?-i)\.jpg

Here's a screenshot of the search dialog:

User generated image
Make sure you tick the RegEx box.

It is not free, but it is among the best 46 dollars (USD) that I've ever spent. Well, I probably spent less many years ago when I bought it (and all upgrades have been free), but that's what a personal license costs today. Also, the personal license grant is generous. Here's a quote:

"The registered version may be installed on as many computers as desired, as long as it is used by only one person at any one time (I.e. one installation at home and one at the office used by the same person). Therefore you need only one licence for a port connection between two computers. The usage by multiple people at the same time (on multiple computers) requires additional licences."

Furthermore, it is shareware, and you may download a fully functional version to see if it works for you before making a purchase.

Besides that feature you're looking for, it is a phenomenal file manager — I never use Windows/File Explorer. I use Total Commander for all file manager functions — and then some! The product does lots of other stuff, such as having an FTP client, folder synchronization, file comparison tools, etc., but I have limited my response to addressing just your issue. Btw, the support is fabulous. When I send an email to tech support, I always get a prompt, accurate answer. In nearly two decades of using this file manager, from Windows 95 through my current 64-bit W7/W8/W10, it has never messed up a file.

As a disclaimer, I want to emphasize that I have no affiliation with this company and no financial interest in it whatsoever. I am simply a happy user/customer. Regards, Joe
"dir *.jpg /s > %temp%\all.txt | findstr /i "JPG" %temp%\all.txt

this works

of course it's not exploder, but it works. "



Nice :)  Now I see what you were getting at.
save in c:\windows\system32\xdir.bat:

dir *.%%1 /s > %temp%\all.txt | findstr /i "%%2" %temp%\all.txt
notepad %temp%\all.txt

Open in new window




Useage:
xdir jpg JPG

Just navigate to the any directory
Avatar of rgb192

ASKER

can you please write proof that windows 7 does not support native case search. so I can be sure and open another question about third party tool
I can't provide "proof", but if you do a web search for "windows explorer case sensitive search", you'll find many folks looking for the feature and every response saying that it can't be done in native W7, and that a third-party tool is required. I followed at least a half-dozen links and all of the threads reached the same conclusion. I don't know if that's "proof" enough for you, but I'm pretty much convinced of it, although I'm certainly open to someone showing otherwise. Regards, Joe
ASKER CERTIFIED SOLUTION
Avatar of ☠ MASQ ☠
☠ MASQ ☠

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Wow this question is still active?
Hey, MASQ, I would call that "proof"! Awesome link!
I still like choward's strategy -

1) Output the results in whatever case they are because Explorer doesn't distinguish.  
2) Create a text file of the results.
3) Analyse the text file using a Windows tool that can pick upper case from lower.  

Coming up with programmatic workarounds for Windows' inadequacies like this is one of the strengths of this site.

Using a free third-party tool is still a bit quicker though ;)
Or even a non-free one. :)  And not just for case sensitive searches, but a real file manager that can do lots of good stuff.
I am guessing that the ultimate aim here would be to change all the uppercase .JPG extensions to .jpg.
Some image editing applications, scanning software, etc. are annoying in that they create files with uppercase image extensions.  I recently created a batch file to find and change uppercase JPG extensions to lowercase on my work's computer, and it used the same principle as choward16980 suggested.  Unfortunately the earlier request for "proof" ticked me off a bit and I really can't be bothered posting the batch file.
Avatar of rgb192

ASKER

Now I am 100% sure that I need a third party tool.
Thanks for evidence and sorry for asking.