Page 1 of 1 1
Topic Options
#47983 - 1999-08-02 09:13 AM %ERRORLEVEL%and EXIT @RAS doesn't work for Win95
Anonymous
Unregistered


I have problem to display the errorlevel of kixstart script on Win95 workstations

;logon batch file
%windir%\kix32.exe logon.kix
echo RAS connections = %ERRORLEVEL%
if NOT ERRORLEVEL 0 goto end

;logon.kix
;some kix commands
exit @RAS

For WinNT exit code is displayed properly (no matter @RAS=0 or @RAS<>0), but for Win95 %ERRORLEVEL% variable is not set at all.

Any help would be appreciated,

Robert

Top
#47984 - 1999-08-03 02:34 PM Re: %ERRORLEVEL%and EXIT @RAS doesn't work for Win95
Anonymous
Unregistered


Do you have the KixRPC service installed ?
Top
#47985 - 1999-08-09 05:03 AM Re: %ERRORLEVEL%and EXIT @RAS doesn't work for Win95
Anonymous
Unregistered


This doesn't have anything to do with the kxrpc service being installed or not.

There are several things that do not work in your batchfile.
First: the if errorlevel 0 test is true for every errorlevel greater than or equal to 0 if you execute it in a batchfile. That you put a not in front doesn't change that principle.

Second Kixtart does return the errorlevel it is just that Windows95 doesn't let you retrieve the errorlevel as easy as Windows NT.

I think you could save yourself a lot of work by recoding the batchfile and use kixstart for the biggest part.

Good Luck
Rene

------------------

Top
#47986 - 1999-08-14 10:12 AM Re: %ERRORLEVEL%and EXIT @RAS doesn't work for Win95
alex Offline
Fresh Scripter

Registered: 2002-01-16
Posts: 8
I agree. Don't mix batch files with kix scripts. Theres no point. Do it all kix.
On win95 machines replace lmscript.exe with kix32.exe and set user profile to run logon (no file extention) Then machines with LMScript replaced run login.kix and machines without lmscript replaces run login.bat which will then install kix on the PC and continue the kix script

Top
Page 1 of 1 1


Moderator:  Glenn Barnas, NTDOC, Arend_, Jochen, Radimus, Allen, ShaneEP, Ruud van Velsen, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 2312 anonymous users online.
Newest Members
fgarcia, Viginette, ManuvdWielNL, Sir_Barrington, batdk82
17889 Registered Users

Generated in 0.131 seconds in which 0.107 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org