vbscript - VBS - script works on Windows 7 a doesnt work on Windows 8 -


whats wrong? code works on windows 7 , doesnt work on windows 8. looks error code null time.

dim objshell, reglocatename, reglocatedn0, strname set objshell = wscript.createobject("wscript.shell") on error resume next set objuser = getobject("ldap://" & struser) set objsysinfo = createobject("adsysteminfo") struser = objsysinfo.username set objuser = getobject("ldap://" & struser) strname = objuser.fullname strphone = objuser.homephone  reglocatename = "hkey_local_machine\software\activa\activatsp\calleridname0" reglocatedn0 = "hkey_local_machine\software\activa\activatsp\dn0" set shell = createobject( "wscript.shell" ) shell.regwrite "hkey_local_machine\software\activa\activatsp\authtype", 1, "reg_dword" 'shell.regwrite "hkey_local_machine\software\activa\activatsp\calleridname0", "" & strname , "reg_sz" objshell.regwrite reglocatename,strname,"reg_sz" objshell.regwrite reglocatedn0,strphone,"reg_sz" 'shell.regwrite "hkey_local_machine\software\activa\activatsp\dn0", "750", "reg_sz" shell.regwrite "hkey_local_machine\software\activa\activatsp\outgoingcontext", "from-internal", "reg_sz" shell.regwrite "hkey_local_machine\software\activa\activatsp\agentcontext", "from-internal", "reg_sz" shell.regwrite "hkey_local_machine\software\activa\activatsp\host", "192.168.31.51", "reg_sz" shell.regwrite "hkey_local_machine\software\activa\activatsp\user", "activa", "reg_sz" shell.regwrite "hkey_local_machine\software\activa\activatsp\password", "outlookhbrp", "reg_sz" 


Comments

Popular posts from this blog

curl - PHP fsockopen help required -

HTTP/1.0 407 Proxy Authentication Required PHP -

c# - Resource not found error -