Accessing Basic Functions Through cmd

Posted On // Leave a Comment



In my last post I have introduced you to the command prompt and its customizations. Now in this post I will have a brief description of accessing basic functions through cmd.

Before we start I would inform you that all the  instructions of this post are done practically on windows 8 cmd so there may be slightly change in the format of the commands than it was used to be at windows XP.  

But still I will provide the old format too.And you can type the commands in Uppercase and lowercase too i.e. Capital letters or small letters. 

And at the end of this post I have a live tutorial to make everyone understand.

From this post you will able to learn


1.       View the contents of Directory.

2.       Create a directory.

3.       Change from one directory to another.

4.       Change from one drive to another.

5.       Copy files.

6.       Rename files.

7.       Delete files

Commands Used

Just type the following commands in the cmd for various functions and press enter.


DIR – this command is used for viewing the directory.

         DIR

Directory is simply a structure which contains references to the other files or folders from the computer.

MD – stands for make directory. To create a directory we have to type
          
         MD directory name.


CD – this stands for change directory. And the format for changing the directory is

          CD directory name.


To change back simply to root directory i.e. main directory simply type the command

         CD\



To back one level up when you are inside a directory just type

          CD..


To change from one drive to another you just have to follow these commands

Simply type the name of the drive followed by colon like this

           E:    

This command will take you to the E drive.


Now copying files is a normal task which everyone performs.


To copy files type  
         
         COPY source destination

This method will not copy the directory it will only copy the file inside the directory.

Or if you have windows xp or the above method does not works then try this syntax
   
          copy c:\windows\notepad.exe c:\fruit

After you have copied the file to the next drive,then to rename the file enter the following Syntax

           ren oldname newname

and if you want to rename folder then follow the syntax


ren "old name" "new name"


Deleting a file


To delete a file use the following syntax

             del filename


Some terms used with command prompt

Wild Card : Symbol  used to replace or represent one or more character. Wild cards are either an asterisk (*).  For example  in cmd dir *.mp3 will show all the files associated with .mp3 extension.

Switches : It modifies the way as MS – DOS carries a command. Generally a switch is followed by / a one or more letter or number.
Like dir /w  it is used to tell the cmd to show the directory with file name listed in wide format.

Root Directory : It is the main directory where we creates many other sub directories. We can say there root directories as drives.



As currently I am also in learning phase so I am able to provide only limited terms. I hope you will share your knowledge with me in comments.

0 comments:

Post a Comment