Endoro wrote:We cannot get the cmd %ERRORLEVEL% here.
defined explicit exit if you want
Code: Select all
C:\> awk "BEGIN{ if ((\"ddd\" | getline) <= 0 ) exit(-1) ; }" 2>nul
C:\>echo %errorlevel%
-1
Moderator: DosItHelp
Endoro wrote:We cannot get the cmd %ERRORLEVEL% here.
Code: Select all
C:\> awk "BEGIN{ if ((\"ddd\" | getline) <= 0 ) exit(-1) ; }" 2>nul
C:\>echo %errorlevel%
-1