How to Copy Directories in DOS

dell-inspiron-1525My friend Mitch came by today with a really bad computer problem. His Dell Inspiron 1525 laptop wouldn’t start and the screen was completely blank. I suggested that we try to load it in Safe Mode, but that didn’t help. When I pressed F8, the screen was still blank. All I could see was the Dell logo, then everything disappeared. Nothing I tried worked. I could get into BIOS, but none of the options solved the problem (for example Load defaults).

After a while and several attempts to load Windows Vista, I got to the Windows Repair and Recovery options menu. The repair option failed, and diagnostic tests showed that the hard drive had some errors, so there was no way that Windows would start normally. However, Mitch had hundreds of photos on the disk and no backup. Obviously he wanted to recover those.

The next time I loaded the recovery options menu, I opened the Command Prompt and found the directory I was looking for under C:\Users\Mitch. If you are not sure how to find your directory, start by typing C: and then DIR to display the contents. If you recognize the folder, you can open it to display the contents by typing CD nameOfDirectory and then DIR. To go up a level, type CD..

If you want to copy a directory with all subdirectories, follow these steps:

  • Plug in a USB memory stick with a large enough capacity to store all your data
  • Make sure you know which drive letter points to the USB stick. If you have a CD/DVD drive with letter D, the USB stick should be E:. If not, try F:
  • Navigate to the destination folder on the USB stick. I had to type E:
  • My USB stick had a folder called Mitch because I created it earlier on another computer, so I changed to this directory by typing CD Mitch. You don’t have to create this directory, but it helps, especially if the folder you’re copying has lots of files and directories.
  • Next, I typed Xcopy C:\Users\Mitch /E:\Mitch
  • This command copied all files, directories and subdirectories within the Mitch folder on the C: drive to the Mitch folder on my USB stick.

Another example would be C:\temp /E to copy the temp folder in C: to the external drive E:

The xcopy command helped a lot, because I was able to recover and back up all photos from the Dell laptop. And Mitch was happy again!

Post a Comment