0
@echo off

set /p Pause=Before
>nul
set /p Pause=After

(@edit Before >nul there supposed to be sign, but it's not visible in post.)
What does this script do, is print "Before" wait till user presses enter, "Bleeps" and prints "After", after pressing enter application stops. But output is:

'' is not recognized as an internal or external command,
operable program or batch file.

I tried >nul and @echo off as you see. But it still appears. How to get rid of it?

Edited by RikTelner

2
Contributors
4
Replies
24
Views
3 Years
Discussion Span
Last Post by RikTelner
0

Hello,

Try this instead:

@echo off
REM start of batch file
echo BEFORE
REM wait for them to press a key
pause
echo AFTER

You will notice that the REM lines are not printed as they are remarks

0

I do know they're not printed. But the problem is, I need something executed but it prints output, which I don't want being output.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.