Creating Files Using Windows DOS Commands

by BrysonH4 in Circuits > Microsoft

516839 Views, 12 Favorites, 0 Comments

Creating Files Using Windows DOS Commands

prompt.png

This will teach you how to use some basic Windows DOS commands. We will navigate to our desktop, create a folder, and create a file within that folder.

Click Start.

In the Search Box Type Cmd.

open command prompt.png

Press Enter

prompt.png

This will open your command line prompt. It will usually look like a big black or white box with a blinking cursor inside.

Type- Dir Then Press Enter

dir.png

This will display all the directories (folders at your current directory level). Normally your computer starts you at the user level. Look through the list, desktop should be listed, if it is not feel free to use a different folder in the following steps.

Type- Cd Desktop and Press Enter

cd desktop2.png

The cd (change directory) command is how we navigate to different directories (folders) in in our command line prompts. Your command line should now say desktop before your cursor. We are now ready to create another folder.

Type- Mkdir YourName Then Press Enter

mkdir.png

You can put your own name, or whatever you would like to name your new folder in place of YourName.

mkdir is the make directory command. After pressing enter, we can now check if we have succeeded.

Minimize Your Command Prompt

new folder.png

Navigate Back to Your Desktop to See Your Newly Created Folder.

Return to Your Command Line Prompt

Type- Cd YourName Then Press Enter

cd YourName.png

This will move you into the directory you just created.

Type Notepad YourName.txt Then Press Enter

If prompted to create a new notepad file select yes.

This will open a new notepad file.

In the Notepad File Type This Is My First File Created Using Command Line Prompts.

Click File Then Save.

notepad file.png

Close the Notepad File and Return to the Command Line Prompt.

Type- Type Yourname.txt

type yourname.png

This will display what is written in the file you created.

Congratulations! You Have Learned Some of the Basic Windows DOS Commands!