General discussion

Locked

Our Login script wont run on XP

By boomio ·
Any idea's why this could be happening???

Here is the start of the login script:
------------------------------------------------
@echo off
rem use /d after the .scr reference below to get into debug mode


Rem Detect OS (NT or other)

:NT_XP
kix32.exe login.scr

:end


Exit

---------------------------------------------
(This is login.scr)
---------------------------------------------
;cls

;TO CHECK FOR RAS

if @ras>1
"RAS, script will not be run"
exit
endif

;WINDOWS 9X SECTION
if @inwin = 2
"Windows 9x, script will not be run"
exit
;end 9x section
endif


function MemSize()
dim $
$=createobject('shell.application')
$MemSize=$.GetSystemInformation('PhysicalMemoryInstalled')
endfunction

;Get model description
;$rv_cpu=READVALUE("\HKEY_LOCAL_MACHINE\software\Microsoft\Windows\CurrentVersion\WindowsUpdate\OemInfo", "WbemProduct")
;@rv_cpu

SET "fullname=@FULLNAME"

;at(1,1)
;log details
"Recording login details" + chr(13) + chr(10)
"Please wait until the script has finished" + chr(13) + chr(10)
shell "%comspec% /c echo @date, @time, @userid, @fullname, @address, @ipaddress0, @wksta >> \\<server>\logfile.txt"


;SHELL '%comspec% /e:512 /c MEM | FIND "Total memory" >> \\<server>\hw.txt'
;SHELL '%comspec% /c MEM | FIND "Total memory" >> \\<server>\hw.txt'
;set time to the server
"Setting time" + chr(13) + chr(10)
settime "\\<server>"

;This will install Winsock client
:WINSOCK
;IF (EXIST ("C:\mspclnt\mspclnt.ini") = 0)
;MESSAGEBOX ("Your system will now be updated and then restarted, click OK to continue", "Winsock Install", 0, 20)
;"Installing Proxy client" + chr(13) + chr(10)
;use \\<server>\mspclnt
;Shell "%comspec% /e:1024 /c \\<server\mspclnt\setup.exe /UA"
;ENDIF


;determine office from IP address
$address=@IPADDRESS0
$subnet=SubStr($address,9,3)
$floorID=SubStr($address,13,3)

;set global variables depending on office
Select

This conversation is currently closed to new comments.

3 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

by Toivo Talikka In reply to Our Login script wont run ...

The script looks healthy, even the slightly unusual practice of using $ as a variable name.

However, you need to check for errors after key commands or functions using Windows resources, like settime:

IF @ERROR <> 0
"error " + @ERROR + " " + @SERROR
ENDIF

You may then see e.g. error code 1314 and its explanation: "A required privilege is not held by the client".

Please provide more information about what is not working. Do you get an error message?

Does the script work in Windows 9X or NT? Do other KiXtart scripts work in your Windows XP environment?

Do you launch the script from the user profile or from Group Policy Object?

Have tried to run the script as it is from Windows XP when the user is already logged in?

Have you tried to run it in debug mode?

Collapse -

by boomio In reply to

Poster rated this answer.

Collapse -

by boomio In reply to Our Login script wont run ...

This question was closed by the author

Back to Desktop Forum
3 total posts (Page 1 of 1)  

Related Discussions

Related Forums