I'm studying today windows Under the system bat script , You want to traverse a directory and output the details of all the files in that directory . After a lot of search and exploration , This can be done with the following code :
@echo off set source_dir="C:\Users\leon\Desktop\test" for /R %source_dir% %%f
in(*.*) do ( echo Full path information : %%f echo Directory information : %%~dpf echo File prefix name : %%~nf echo
File suffix name :%%~xf echo Full file name : %%~nxf echo Path without suffix : %%~dpnf echo File modification time : %%~tf echo
File content size :%%~zf Byte ) pause
The results are as follows :

Full path information : C:\Users\leon\Desktop\test\test.txt
Directory information : C:\Users\leon\Desktop\test
File prefix name : test
File suffix name : .txt
Full file name : test.txt
Path without suffix : C:\Users\leon\Desktop\test\test
File modification time : 2020/07/09 14:58
File content size : 12 Byte
Please press any key to continue . .

If you just list a certain type of file ( such as *.doc), Then change it to the following statement :
@echo off set source_dir="C:\Users\leon\Desktop\test" for /R %source_dir% %%f
in(*.doc) do ( echo Full path information : %%f echo Directory information : %%~dpf echo File prefix name : %%~nf echo
File suffix name :%%~xf echo Full file name : %%~nxf echo Path without suffix : %%~dpnf echo File modification time : %%~tf echo
File content size :%%~zf Byte ) pause

Technology
©2019-2020 Toolsou All rights reserved,
What are the protection measures for website security ? Talking about uni-app Page value transfer problem Remember once EventBus Project issues caused by memory leaks I've been drinking soft water for three years ? What is the use of soft water and water softener Time conversion front desk will 2020-07-17T03:07:02.000+0000 Into 2020-07-17 11:07:02 Chuan Shen Count the number of letters (java Language implementation ) Time format 2020-01-13T16:00:00.000Z Medium T and Z What do they mean , How to deal with it msf Generate Trojan horse attack android mobile phone The world's first free open source ERP Odoo Ubuntu The best development environment What's the difference in server prices ?