Batch file

2 minute read
batch file entity

Home » Vocabulary » Thing » Batch file

In DOS, OS/2, and also Microsoft Windows, a batch file is a script file, or a text file containing a series of commands to be executed by a command interpreter, such as Command Prompt in Windows.

Batch files: how they work, what are they good for, and how do we use them

  1. How batch files work
  2. How to use a batch file
  3. What are they good for

How batch files work

A batch file may contain any command the interpreter accepts interactively at the command prompt. A batch file, with .bat extension, may also have constructs that enable conditional branching and looping within the batch file.

Windows will recognize a .bat extension as an executable, although they are composed of text commands. So, you can open a batch file even with a Notepad and it will show you the code that makes up the file.

How to use a batch file

First of all, to use a batch file, you need to open it. To do that in Notepad, right-click on the file and select Edit. There are text editors that are more useful for batch files because they highlight certain parts of the text.

batch notepad open

batch notepad open text

Also, .bat files are executable files that can perform specific tasks such as erasing certain files. In this sense, the function is similar to the Command Prompt, only that you access .bat files and not writing commands in the CMD dialog box.

What are they good for

Batch files have many roles. They are versatile tools that will make your life easier (if you know how to use them). For example, you can open multiple folders using batch files. Here is a complete guide that shows you how to do that.

Also, you can convert or create batch files to serve you on your purposes. Converting a modified batch file to .exe or .txt is wise because edited batch files can severely affect your computer.

Moreover, batch files can help you fix certain issues with your computer, such as startup folder not working in Windows 10.





Next up

The cumulative update KB4515384 affects PIN? Try this!

Alexandru Voiculescu By: Alexandru Voiculescu
2 minute read

The September 10 Patch Tuesday for Windows 10 version 1903 has arrived. Many users were thrilled about KB4515384, hoping the update will solve many problems. […]

Continue Reading

KB4516421 update fixes a crucial audio issue in Windows 10

Alexandru Voiculescu By: Alexandru Voiculescu
2 minute read

Windows 10 version 1903 has a new non-security update that addresses a problem in which users are unable to use USB Audio 2.0 multi-channel microphones […]

Continue Reading

How to fix the VPN Client agent error for Cisco AnyConnect

Matthew Adams By: Matthew Adams
2 minute read

Cisco AnyConnect is VPN software that incorporates advanced protection for blocking malware at endpoints. However, some users have said that they can’t install or launch […]

Continue Reading