I would like to get the list of files exist in folder and subfolder with full path.Don't want any blank folder or subfolder path in list.
Example. (File exist on path) ~\Folder1 \Subfolder1 \File1.jpg
(No file on this path, blank folder) ~\Folder2 \Subfolder2\
(File exist on path) ~\Folder3 \Subfolder3 \File3.png
*Result.\Folder1\Subfolder1\File1.jpg.\Folder3\Subfolder3\File3.png
I tried dir /s /b>list.txt command in cmd but also getting path on blank folder path that I don't want.
Simply ask dir
to remove directories... Being a directory is considered as an attribute.
dir /s /b /a:-D > list.txt
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.