
- Batch File Programming - Dave Corby
A batch file is a short list of instructions that runs one or a sequence of programs. This can be very useful when a program is run repeatedly with a complex set of arguments or a sequence of programs are often run together.
Batch Files Save Time
When instructions are typed at a command line then mistakes can be made. If the command is complex or it is run many times on different files then a batch file can save a lot of time.
Using a Batch File Creator
A creator can help form a batch file and provide assistance. For example the batch commands can be selected from a list together with the available parameters on the selected command. Help can be provided by showing a description of how to use each command and parameter. The creator can also help by providing easy access to all batch files for editing and updating.
Batch File format
Batch files are standard text files containing the exact text that would have been typed on the command line. One exception to this is that it may contain the full directory structure for each instruction. When typed in manually, commands are often run from the directory they are stored in, but one useful feature of a batch file is that they can be created to run from anywhere by pointing to the different locations of the programs.
Batch Files Can Have Arguments
Another useful feature of batch files is that they can have parameters, otherwise known as arguments. If a command is run on different files then this can be added to a batch file when it is created. The batch file can then be used like a command with the file name as a parameter.
Additional Batch Commands
There are many additional batch commands that can be used to give extra functionality.
An excellent help site for manually creating batch files can be found at Computer Hope - Batch File Help
Examples of Batch file Creator Applications
Here is an example from DeskTopEngineer to create a quick batch file to copy some files and start a program:
This is a link to an open source project. These are projects where the source code is shared so everyone can join in creating a program and in this case an application to create batch files.
Batch File Creator Open source project
This is an extensive application that can be used to create batch files:
KaSaB Batch File Creator
