How can I get this batch file to read all physical and mapped drives? It works fine with C: but will not read any other drive.
@echo off
set filePath=
for /R c:\ /d %%a in (*) do if exist "%%a\FileName" set filePath=%%a& goto continue
:continue
if defined filePath echo %COMPUTERNAME% %username% yes >> \\server\%computername%.txt
No comments:
Post a Comment