Link to home
Start Free TrialLog in
Avatar of arsmed840
arsmed840Flag for United States of America

asked on

Logon Script

Hi,
we have a windows 2000 domain controller and I have setup a logon script (.vbs) under profile on my account in AD. The path I used is \\machinename\netlogn\login.vbs.
I tried running the scrip by itself and the script is working fine. Not sure why its not working when I login to my computer using the network credentails..Here is the script I am using.

Const HKEY_CURRENT_USER = &H80000001

strComputer = "."
Set objReg = GetObject("winmgmts:\\" & strComputer & "\root\default:StdRegProv")
 
strKeyPath = "SOFTWARE\Microsoft\Internet Explorer\Main"
ValueName = "Start Page"
strValue = "http://testhomepage.com"
objReg.SetStringValue HKEY_CURRENT_USER, strKeyPath, ValueName, strValue

Avatar of 0xSaPx0
0xSaPx0

add a pause to see what error is generated.
Avatar of arsmed840

ASKER

I added..
WScript.Sleep(1000)..I didnt see any messages. I am not sure if it is even running the script...
That could be the problem, how are you implementing the login script?
In the AD, i put the script on the user profile: under profile tab and  under logon script.
Can the user access the path where the login script is stored?

ASKER CERTIFIED SOLUTION
Avatar of purplepomegranite
purplepomegranite
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Details for group policy are here, it would be worth a look: http://technet.microsoft.com/en-us/windowsserver/grouppolicy/default.aspx