BATCH FILE:
Batch files are executable text files that contain a series of commands. Thus these are like small programs, which perform specific tasks, like loading certain applications in the memory. The most common batch file is autoexec.bat a system file that contains many MS DOS commands to initialise your system .If you want to create your own batch file, all you need to know are some DOS commands. For example, if you intend to maintain a log of the instances when you powered on your PC, open Notepad and create a text file with the following commands: @ECHO OFF ECHO %Date% %Time% bootlog.txt Here @ECHO OFF, ensures that nothing is printed on the screen while the commands are executed .The next line creates the bootlog.txt file and adds the date and time to the end of the file. Now, these lines are executed whenever your system boots up. The instances when your system was booted up are recorded in bootlog.txt. A batch file is a script file in DOS, OS/2 and Microsoft Windows. It consists of a series of commands to be executed by the command-line interpreter, stored in a plain text file. A batch file may contain any command the interpreter accepts interactively and use constructs that enable conditional branching and looping within the batch file, such as IF, FOR, and GOTO labels. The term "batch" is from batch processing, meaning "non-interactive execution", though a batch file might not process a batch of multiple data. The detailed handling of batch files has changed significantly between versions. Some of the detail in this article applies to all batch files,while other details apply only to certain versions.
No comments:
Post a Comment