I have a quite extensive batch file for swapping project files around and includes a few menu's and clearscreen commands. I have included the command - @Echo off to avoid all commands being output. The batch file works fine except it outputs the statement "Echo is off" when I refresh the screen for a new menu. Is there any way to stop the "Echo is off" statement?
2 Answers
Look for a line that has echo and either nothing after it or a variable that is empty.
This is good to echo a blank line
echo(
and similarly this will echo a blank line and not a "echo is off" error when the variable is empty.
echo(%variable%
The echo
statement is question is attempting to echo a variable which is not set.
The easy way is to replace echo %var%
with echo(%var%
echo %variable%
somewhere and variable is not defined.