1.

Solve : how to search for a folder in dos?

Answer»

Hi experts,

How to search for FOLDER in dos?how to write a BATCH FILE for this?the situation is like this
if i GIVE a folder name it should search and give the FULL path.
I have a batch file for searching files but am not able to get the folder path i
f i give a folder name.
please advise me

waiting for a lead....

Rgds,
PrajithMaybe something like this:

Quote

@echo off

set /p FILE="What is the file/folder name? "
cls

for /f "delims=" %%i in ('dir "C:\%FILE%" /b /s') do echo %%~fi | more
echo.
pause

??Have to use
dir
dir ...
or assocset a=%cd:~0,1%
dir %a%:*.* /a:d /b /s


Discussion

No Comment Found