How to delete a file or folder using the Command Prompt
Welcome, Guest. Please login or register. Did you miss your activation email?


Britec Computer Tech Help Support Forums  « Tutorials « Tutorials and How-to « How to delete a file or folder using the Command Prompt
Pages: [1]
  Print  
Author Topic: How to delete a file or folder using the Command Prompt  (Read 508 times)
Britec
Administrator
Hero Member
*****
Posts: 3497



View Profile
« on: June 19, 2010, 02:58:15 PM »

How to delete a file using the Command Prompt


To start the command prompt in Windows left click Start then Run. Type in "CMD" (without the "") and hit Enter.

1. First locate the file that you would like to delete.
2. Then on the command prompt type:

del filename.txt



3. and then hit Enter.
4. Now check to see if file has been deleted type:

dir



and then hit Enter has file has been deleted?

Note: If you want to delete a file with spaces in its name you must wrap the name in "". For example:

del "filename 1"

If you want to delete more than one file you can do so like this:

del "filename 1.txt" "filename 2.txt" del "filename 3.txt"

How to delete a folder using the Command Prompt

To start the command prompt in Windows left click Start then Run. Type in "CMD" (without the "") and hit Enter.

1. First locate the folder that you would like to delete.
2. Then on the command prompt type:

rmdir foldername



3. and then hit Enter.

4. Now check to see if file has been deleted type:

dir



and then hit Enter has folder been deleted?

Note: If you want to delete a folder with spaces in its name you must wrap the name in "". For example:

rmdir "foldername 1"


If you want to delete more than one folder you can do so like this:

rmdir "foldername 1" "foldername 2" "foldername 3"
« Last Edit: August 07, 2010, 03:49:43 AM by Britec » Logged



BJseal91
Hero Member
*****
Posts: 699



View Profile
« Reply #1 on: June 20, 2010, 02:54:36 AM »

Great Tips For begginers Brian
good post Smiley

BJseal91
Logged
Britec
Administrator
Hero Member
*****
Posts: 3497



View Profile
« Reply #2 on: June 20, 2010, 03:35:50 AM »

Yeah good way to learn how to use a Commans Prompt
Logged



tejen
Newbie
*
Posts: 2


View Profile
« Reply #3 on: December 18, 2010, 09:40:07 PM »

Great Tips You Rock
Logged
Pages: [1]
  Print  
 
Jump to: