How to copy all *.txt files from c drive to d

December 22, 2010 at 22:49:40
Specs: Windows XP
What will be the dos command to copy all the *.txt files from my root/current drive to another destination?

i precisely mean to get all the *.txt files from all the directories and subdirectories.

i.e HOW TO COPY ALL *.TXT FILES FROM C DRIVE TO D DRIVE.


See More: How to copy all *.txt files from c drive to d

Report •

#1
December 22, 2010 at 23:58:40
In the command prompt type "COPY /?".

Can I put a question here?


Report •

#2
December 23, 2010 at 01:19:06
Use search for *.txt in the C: drive. All .txt files will be found and listed.
Select all files form the root of C:, then cut and paste to the new desired location (D: drive).

___________________________________________
When everything else fails, read the instructions.


Report •

#3
December 23, 2010 at 01:57:33
UNTESTED

FOR /F "TOKENS=*" %%J IN ('DIR /B /S *.TXT') DO XCOPY /Y %%J D:\

Happy is ONE who says I am an OttoMAN.


Report •

Related Solutions

#4
January 2, 2011 at 05:25:56
cd C:\
copy *.txt D:\

Report •

#5
January 2, 2011 at 07:43:31
xcopy C:\somefolder E:\backupfolder /D /E /C /R /H /I /K /Y

make changes to fit your needs C:\*.txt D:\backupfolder


Report •

#6
January 2, 2011 at 11:05:19
Digging around in a todo dir I came across this.
Creates an x.bat. Perhaps it will be of use to you....or not ..lol

You can find the switches and use of at
http://www.microsoft.com/resources/...

---------------- copy and paste below into notepad and save as xcop.bat--------

cls
@echo off
color 2f
:start
echo Xcopy Bat
echo Type in source IE c:\*.txt hit enter
echo Then type in destination IE G:\backup
echo When finished hit enter
set FILES=
set /p FILENAME=Enter the files to copy: 
echo Your input was: %filename%
pause

:two
set INPUT=
set /P INPUT=Type destination input: %=%
echo Your input was: %INPUT%

pause
echo xcopy %filename% %INPUT% /D /E /C /R /H /I /K /Y >>temp.txt
copy temp.txt >x.bat

exit


Report •

Ask Question