An integer is a whole number, like 0, or 9, or 1234.

The basic syntax used to determine if a variable or parameter is an integer is:

if VariableOrParameter EQU +VariableOrParameter CommandToExecuteIfInteger

<b>if %1 EQU +%1 @echo %1 is an integer.</b>

<b>if %1 NEQ +%1 goto error</b>

<b>if %var% EQU +%var% @echo Variable var contains an integer.</b>

<b>For /f "Tokens=*" %%a in ('type %1') do (
 if %%a NEQ +%%a @echo Line containing \{%%a\} in file %1 is NOT an integer.