Firstly, we need to be clear of what batch is.
You can make simple games, or useful files with it, and all you need is a notepad!
Goto start, run (or search), type in "cmd"
Ok, now you should have a black screen appearing.
That is a command prompt, it allows you to access your computer in a different way.
Alright, let's get to know the commands.
Type in "help"
You will see a list of commands that you can access. You do not need to know all of them.
Now open a notepad. (or any other extended version such as Notepad++)
If you have a notepad full of batch commands and save it as batch file (.bat) , the computer will then run the commands from top to bottom rapidly.
Note : You do not need cmd to be opened, it will start a cmd when it is ran.
Now you can close your command prompt if you wish to.
In your notepad, type in the first line "@echo off"
This makes a difference, not in how the file works, but how it looks.
without "@echo off" as your first line, you will have the line of your command which in my opinion, it's ugly.
The line is now removed with "@echo off"
This is the end of tutorial 00, in tutorial 01 we will start making simple batch files!
沒有留言:
張貼留言