1.

Solve : displayed comment in a batch?

Answer»

how would you make a comment appear on the cmd screen but the script wont exicut it

so it would not exicut the highlighted area

TYPE a number in
1.---
2.---
3.---
type here:well you would have to TURN on ECHO before the comment like so:

Code: [Select]echo on
rem 1,---2,---3,---
echo offThis will do it:

Code: [Select]echo off
cls
echo Type a number in:
echo 1...
echo 2...
echo 3...
set /p Selection=Type here

:: The next line displays the entered number..
echo %Selection%

The Environment Variable %Selection% will contain the number entered.



Discussion

No Comment Found