ATTRIB. EXE
(a) Target File/folder not found = errorlevel 1
(b) Invalid switch = errorlevel 1
(c) Sharing violation (target file in use) = errorlevel 1
(d) Invalid Drive specification = ERRORLEVEL 1
(e) Drive not ready (either Abort or Fail reply) = errorlevel 1
(f) Invalid/wrong num ber of parameters = ERRORLEVEL 1
EXTRACT. EXE
(a) Invalid switch = ERRORLEVEL 1
Fc. Exe
(a) insufficient number of filespecs = ERRORLEVEL 1
(b) Too many filenames on command line = ERRORLEVEL 1
(c) Sharing violation + Abort reply = errorlevel 5
(note:fail reply returns ERRORLEVEL 0)
(d) Drive not ready = ERRORLEVEL 18
(note:fail reply returns ERRORLEVEL 0)
Find. Exe
(a) Target string found (=f0und) = errorlevel 0
(b) Target string Missing (=m1ssing) = errorlevel 1
(c) Find/? = ERRORLEVEL 1
(d) Parameter format not correct = ERRORLEVEL 2
(e) Specified file to search is not found = errorlevel 2
(f) Specified file in use + Fail reply = errorlevel 2
(g) Drive not ready + Fail reply = errorlevel 2
(h) Specified file in use + Abort reply = errorlevel 5
(i) Drive not ready + Abort reply = errorlevel 5
Format.com
(a) Drive not ready = ERRORLEVEL 4
(There is no Abort, retry, Fail stall)
FTP.EXE
(a) Brief help (Use:ftp-h for Brief help) = ERRORLEVEL 2
(b) Error opening script file (file missing) = ERRORLEVEL 2
(c) Invalid switch = ERRORLEVEL 2
More.com
(a) Invalid switch (more doesn ' t accept switches) = ERRORLEVEL 1
(b) Drive not ready (Abort reply) = Errorlelel 5
(note:fail reply returns ERRORLEVEL 0)
Move. Exe
(a) Required parameter missing = ERRORLEVEL 1
(b) Unable to create destination = ERRORLEVEL 1
(c) Unable to open Source = errorlevel 1
(You'll be trying to move a folder from one drive
to another. You are need to use xcopy/s followed by deltree,
Since move won ' t handle folder moves across drives)
(d) Sharing violation + Fail reply = errorlevel 1
(Note:file is nevertheless COPIED, not moved, in the case)
(e) Sharing violation + Abort reply = errorlevel 5
(Note:file is nevertheless COPIED, not moved, in the case)
(f) Drive not ready (Abort reply) = errorlevel 18
(Note:fail reply-unusually-returns errorlevel 1)
Ping. Exe
(a) Unknown host = errorlevel 1
(Usually=name not found on Domainnameserver)
(b) Brief help (with no parameter) = ERRORLEVEL 1
Note:for PING Brief help with/? Switch, ERRORLEVEL is 0
(c) Invalid switch = ERRORLEVEL 1
(and displays the Brief help as OK)
(d) interrupted with [ctrl-c] = ERRORLEVEL 255
SORT. Exe
(a) Invalid switch = ERRORLEVEL 1
(b) Drive not ready (Abort reply) = errorlevel 15
(note:fail reply returns ERRORLEVEL 0)
START. Exe
(a) Start/? (real mode) = ERRORLEVEL 1
(b) Start/? (GUI) = ERRORLEVEL 255
(c) Can ' t find file specified for START = ERRORLEVEL 255
(d) No file association for specified file = ERRORLEVEL 255
(e) Drive not ready = ERRORLEVEL 255
(There is no Abort, retry, Fail stall)
SUBST. EXE
(a) Invalid parameter = ERRORLEVEL 1
(b) Invalid switch = ERRORLEVEL 1
(c) Path not found = errorlevel 1
(d) Drive not ready (Abort reply) = errorlevel
note:fail reply -unusually-returns errorlevel 1)
TRACERT. Exe
(a) Unable to resolve target system name = ERRORLEVEL 1
(Usually=name not found on Domainnameserver)
(b) Invalid switch = ERRORLEVEL 1
(c) Brief help (no parameter) = ERRORLEVEL 1
(d) interrupted with [ctrl-c] = ERRORLEVEL 255
Note:for TRACERT Brief Help, type command without parameters
Xcopy. Exe
(a) File not found = errorlevel 1
(b) Invalid date in/d switch = ERRORLEVEL 4
(c) Invalid number of parameters = ERRORLEVEL 4
(d) Invalid parameter = ERRORLEVEL 4
(e) Device not ready = ERRORLEVEL 4
(f) Unable to create directory = ERRORLEVEL 4
(g) System can ' t find File = ERRORLEVEL 5
(This occurs the device such as NUL is used as Source file)