This content is not available in your preferred language.

The content is shown in another available language. Your browser may include features that can help translate the text.

Archived:Creating a Batch File for my LabVIEW Executable

Updated Apr 29, 2024

NI does not actively maintain this document.

This content provides support for older products and technology, so you may notice outdated links or obsolete information about operating systems or other relevant products.

Reported In

Operating System

  • Windows

Issue Details

I need to create a batch file so that I can run multiple installers during the installation of my LabVIEW executable. What are batch files used for, and what is the correct syntax to use when creating one?

Solution

A batch file is a regular text file (*.txt) except that it has been given a *.bat extension. It can be created with any ASCII text editor such as Notepad or the DOS Editor.  You simply type DOS commands into the file, one command per line.  When you run the batch file, the series of DOS commands will be executed as though the commands were typed at a DOS prompt in a Command window.  

For a list of basic DOS commands see "Additional Information", below.

Additional Information

REM - Records comments (remarks) in a batch file.
COPY - Copies one or more files to another location.
MOVE - Moves files and renames files and directories
DEL - Deletes one or more files.
CLS - Clears the screen.
PAUSE - Suspends processing of a batch program 
ECHO - Displays messages, or turns command-echoing on or off