program.exe
if errorlevel 99 echo ERRORLEVEL 99
if errorlevel 98 echo ERRORLEVEL 98
When I run this with a coded Halt(333) it prints every ERRORLEVEL xx line in the batch...
Re: Pascal Help
By: stizzed to All on Sat Jun 27 2020 04:52 pm
program.exe
if errorlevel 99 echo ERRORLEVEL 99
if errorlevel 98 echo ERRORLEVEL 98
When I run this with a coded Halt(333) it prints every ERRORLEVEL xx in the batch...
My DOS memory is rusty, but IIRC, "if errorlevel x", means catch every error level that is x "or greater".
So if you have your tests in ascending order, it will trip on every one.
Perhaps you want "if errorlevel <x> goto <label>"?
...δεσ∩
Sysop: | digital man |
---|---|
Location: | Riverside County, California |
Users: | 1,041 |
Nodes: | 15 (0 / 15) |
Uptime: | 98:42:58 |
Calls: | 236,120 |
Calls today: | 2 |
Files: | 60,372 |
D/L today: |
209 files (38,991K bytes) |
Messages: | 290,023 |