|
Answer» Hi all:
Please help me to get the code which helps us to get the file size for all the files present under the specified directory. For the files whose size is 0 bytes should be written (file name) to another file.
Thanks in advance.
Suvir SudFeel free to make any changes NECESSARY. The snippet SHOWS one way to solve your request.
Code: [Select]@echo off for /f "tokens=* delims=" %%d in ('dir /s /b C:\*.*') do ( if %%~zd==0 echo %%d >> ZeroByteFile.txt )
Edit: In this case REDIRECTION requires double symbols.
|