• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Windows 2000 DOS Command Line Question

KBtrade

Senior member
I am taking a Windows 2000 DOS class, One of the questions in the case problem is:
From the root directory, copy the files in the "FY 2002" directory to the "FY 2003" directory, and during the copy operation, change the first part of the filename from "2002" to "2003". What command did you enter for this operation?...Thanks in advance, this one has me stumped 😕
 
Well, since there is no DOS in W2K, your question is moot. 🙂

Anyway, if you are talking about a CMD prompt that emulates DOS and assuming all of the files in FY2002 are named 2002xxx, I would do

xcopy \"FY 2002"\2002*.* \"FY 2003"\2003*.*

 
there is no DOS in NT. therefore windows 2000 DOS class is meaningless.
the command prompt in NT is NOT DOS!!

anyway, the answer is:

xcopy /I /E "FY 2002" "FY 2003"

you need the quotes. This assumes the dir "FY 2003" doesn'texist before the copy.
 
StuckMojo - you missed the 2nd part of his question. He needs to copy the files AND change the filenames from 2002xxx to 2003xxx.

 
Let me re-phrase that, it's a Windows/DOS concepts class. The text book we are using is called: Microsoft Windows 2000 MS-DOS Command Line

The 3 files I am working with are called:
2002 Sales Summary #1.xls
2002 Sales Summary #2.xls
2002 Sales Projections.xls

 


<< Bump

Thanks for your help, but I am still stuck on this question...anyone?
>>

bozo1 already answered it...

xcopy \"FY 2002"\2002*.* \"FY 2003"\2003*.*

That will take all files in the directory FY 2002 that have names beginning with 2002, and copy them to FY 2003 replacing the first four characters of their names to 2003.

 
when I try xcopy \"FY 2002"\2002*.* \"FY 2003"\2003*.*

I get this
A:\>xcopy \"FY 2002"\2002*.*\"FY 2003"\2003*.*
File not found - 2003*.*
0 File(s) copied
 
Looks like you left out a space between in the command. A:\>xcopy \"FY 2002"\2002*.* space \"FY 2003"\2003*.*
 
Back
Top