How do I find files where the filename contains a specified string?
You used findstr
. However, findstr
is used to search for strings in files, not strings in the filename itself.
To find filenames containing a certain string you should use dir
("Display a list of files and folders").
Try the following command:
dir j:\documents\post_01\*conversion* > j:\documents\conversion.txt
Sources
Further reading
- An A-Z Index of the Windows CMD command line is an excellent reference for all things Windows cmd line related.