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: | Eric Oulashin | 
|---|---|
| Location: | Beaverton, Oregon, USA | 
| Users: | 104 | 
| Nodes: | 16 (0 / 16) | 
| Uptime: | 02:02:17 | 
| Calls: | 7,076 | 
| Calls today: | 18 | 
| Files: | 9,223 | 
| U/L today: | 
  				1  				files  				 (236K bytes)  | 
  		
| D/L today: | 
  				2,594  				files  				 (1,066M bytes)  | 
  		
| Messages: | 373,761 | 
| Posted today: | 4 |