Page 1 of 1
When I cancel the batch via Ctrl+C The first row deleted
Posted: 25 Nov 2010 05:59
by karzer
When I cancel the batch via Ctrl+C. The first row of the sheet is being deleted(route print). How can I perevent deletion?
Code: Select all
@echo off
set /p IP=
FOR /L %%G IN (0,1,255) DO route delete %IP%.%%G
exit
Re: When I cancel the batch via Ctrl+C The first row deleted
Posted: 25 Nov 2010 06:13
by jeb
Hi karzer,
test the content of IP
Code: Select all
@echo off
set "IP="
set /p IP=
if "%IP%"=="" (
echo Nothing entered or CTRL-Break
goto :eof
)
FOR /L %%G IN (0,1,255) DO route delete %IP%.%%G
exit
jeb
Re: When I cancel the batch via Ctrl+C The first row deleted
Posted: 25 Nov 2010 07:03
by karzer
Thank you, but I pexec it (remcomm) Deleting the first line with the distance I run.
I wonder how the function of ctrl + c to cancel and quit.
remcomm / / host batc_file