2 VARIABLES AND VALUES

Now that we’re ready to start coding, we’ll explore variables, values, and the Batch set command, which assigns values to variables. Although these topics may seem trivial if you’ve coded in other languages, Batch has some unique quirks that are worth noting.

You’ll learn how to display the value of a variable in the console to confirm that it has been set correctly. Additionally, I’ll introduce the command separator, which allows you to enter multiple commands on a single line. I’ll also show you how to create remarks and set variables that are saved on your computer and remain available even after the bat file is ...

Get The Book of Batch Scripting now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.