In the operating system MS-Dos, batch file represents a text file with commands that the command interpreter executes. In MS-Dos, batch files are used to automate and simplify routine or mundane tasks . Batch files have generally file name extensions such as .bat. To write a batch file in the text mode, the use of redirect is compulsory. The batch file in the text mode can be created by using the Echo command. WordPad is useful for saving the file, with the extension of the .bat carried out here.
To write in a batch file in text mode, you just have to use a redirect:
echo text > output_file.txt
To write in an existing file:
echo " Write at the end of the file ">> output_file.txt
Note: The accent will be copied to the DOS format.