『第 258 楼』:
 
 
使用 LLM 解释/回答一下
  
for /f "tokens=5 skip=5" %1 in (1.txt) do @if exist %1 @echo %1 
 
楼主 这句不行 请核实 我是在2003系统运行的 1.txt 是在同一目录下的 
 
1.txt的内容 
 
Volume in drive D is DATA 
Volume Serial Number is C47C-9908 
Directory of D:\tmp 
09/26/2001 12:50 PM 18,426 alg0925.txt 
12/02/2001 04:29 AM 795 bsample.txt 
04/11/2002 04:18 AM 2,043 invitation.txt 
4 File(s) 25,651 bytes 
0 Dir(s) 4,060,700,672 bytes free 
for /f "tokens=5 skip=5" %1 in (1.txt) do @if exist %1 @echo %1 
 
The LZ owner, this doesn't work. Please verify. I'm running it on Windows 2003, and 1.txt is in the same directory. 
 
Content of 1.txt: 
 
Volume in drive D is DATA 
Volume Serial Number is C47C-9908 
Directory of D:\tmp 
09/26/2001 12:50 PM 18,426 alg0925.txt 
12/02/2001 04:29 AM 795 bsample.txt 
04/11/2002 04:18 AM 2,043 invitation.txt 
4 File(s) 25,651 bytes 
0 Dir(s) 4,060,700,672 bytes free 
    
 
  
 |