Microsoft Disc Operating System has never lost its value even Windows has seen evolution to Windows 10. Compiled nearly 11,000 times and has revamped its user interface and across all devices from command based MS-DOS. Still Microsoft ships windows with command prompt to run DOS programs.
Sometimes, we may need to create files such as some BAT script or some configuration files, which we can simply create using DOS Command prompt.
Lets open Command prompt
Prompt means “Assist by suggesting the next words of something forgotten or imperfectly learned.” MS DOS prompt also help you and interfaces with you.
In above line C: (colon) is current drive , (backslash) is symbol for directory (folder), Users is directory name, (backslash) is directory symbol, John is name of folder and > (greater than) is command prompt symbol. This is the place, where you will write command.
1. How to create Folder?
Use following commands to create a folder (directory) in MS-DOS command prompt.
md foldername ↵
mkdir foldername ↵
Meanings of Above Command:
md or mkdir – Make Directory
↵ – Enter Key to execute command.
2. How to create a File?
Use following commands to create a file in MS-DOS command prompt.
copy con filename ↵
Meaning of above commands.
copy con – This command is used for creating new file.
↵ – This is Enter key. This executes command typed in prompt.
–Text–,.. .. .. in DOS mode. – This is text of your file.
^Z ↵ – This is Ctrl+Z key. This saves current file. Alternate for this is F6 key.[/C]
Below is an example using both commands.
... CD Desktop MKDIR Test CD Test Copy con WiFiHotSpot.BAT NETSH WLAN SET HOSTEDNETWORK MODE=ALLOW SSID=John KEY=12345678 NETSH WLAN START HOSTEDNETWORK QUIT ^Z