Re: WSCRIPT.EXE does not set ERRORLEVEL



Syntax !


"Krzysztof Żelechowski" <yecril71pl@xxxxxxxxxxxxxxxx> wrote in message
news:27EE8178-61A8-4C31-B468-987C7AFC3E93@xxxxxxxxxxxxxxxx


"Bill Stewart" wrote:

Krzysztof Żelechowski wrote:

I have noticed that cscript.exe sets ERRORLEVEL but wscript.exe does
not.
Why is that?

It works for me here...

Test.cmd:

@echo off
wscript Test.js
echo %ERRORLEVEL%

Test.js:

WScript.Quit(1);

When I run Test.cmd, I get "1" as output.


Now it is even stranger. It works when run from a shell script but it
does
not work when entered from the command line.

Chris

.



Relevant Pages