Home | Recovery | Cisco How To Net How To | Blog | Search | Forums | Services | Setup Guide | Chicagotech MVP | IT Exam Practice  |  About Us | Contact Us|

 

 

Testing a specific error level using If errorlevel command

In a case you want to check for a specific error level of a program, you may use the following command construct
IF ERRORLEVEL <N> IF NOT ERRORLEVEL <N+1> <COMMAND>

where <N> is the desired number. The <N+1> portion of the command must be calculated as the command is entered, because the MS-DOS command interpreter cannot perform mathematical calculations.
 

Related Topics

DOS Errorlevel command
The combination of the two or more IF ERRORLEVEL or nested IF Errorlevel statements
Testing a specific error level using If errorlevel command

 

Bob Lin Photography services

Real Estate Photography services 

 

  This web is provided "AS IS" with no warranties.
Copyright © 2002-2018 ChicagoTech.net, All rights reserved. Unauthorized reproduction forbidden.