?
Solved

Need help to make some changes under the following registry hive HKEY_CURRENT_USER\

Posted on 2010-11-16
6
Medium Priority
?
1,452 Views
Last Modified: 2012-06-27
Our users are do NOT have admin rights to their computers. I am facing the following problem since the MSI provided by MS http://support.microsoft.com/default.aspx?scid=kb;en-us;175500 needs admin right in order to be installed.

The problem is that if I deploy the MSI with SCCM I can choose to run it with admin rights however since the change is applied to the HKEY_CURRENT_USER\ hive I guess the change it is NOT applied correctly to the current user.

Is there anyway that I could make this change? Basically I need the MSI to be executed as the user so that the changes to the HKEY_CURRENT_USER\Software\Internet Explorer\ etc... are applied to the current user.

If SCCM can not be used is there anyway to do this with a script or ADM template via GPO?

Thank you
0
Comment
Question by:llarava
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 1

Expert Comment

by:wlramsey
ID: 34147357
I have ran many installs with a VBScript as their login script.  You could do something like this:

	Set Shell = CreateObject("WScript.Shell")
	Set objNetwork = CreateObject("WSCript.Network")
	Set objfilesys = CreateObject("Scripting.FileSystemObject")
        If objfilesys.FileExists(strfilepath32 & strfilename) Then
		WScript.StdOut.Writeline "Symantec (32) Installed"
	Else 
         	Wscript.stdout.writeline "Installing Symantec Antivirus (32), please wait..."
		'Run 32 bit installer
		Shell.Run chr(34) & "\\servername\path_to_install.exe" & chr(34)
       End If

Open in new window


Since this runs after the user logs in, it should have access to their HKCU Hive.

At least, I have never had any problems running scripts this way.
0
 

Author Comment

by:llarava
ID: 34147459
Thank you for your help but is not going to work.

The problem is that the MSI needs admin rights and changes have to be applied to the HKEY_CURRENT_USER\ hive
So if I run the script with any other user like the administrator then the registry changes will NOT be applied to the right hive.

Using a Registry Editor such as Regedt32.exe, open this key:
HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Styles

Note If the Styles key is not present, create a new key that is called Styles.
Create a new DWORD value called "MaxScriptStatements" under this key and set the value to the desired number of script statements. If you are unsure of what value you need to set this to, you can set it to a DWORD value of 0xFFFFFFFF to completely avoid the dialog.

 
0
 
LVL 6

Expert Comment

by:ipajones
ID: 34147886
regedit /s works when user access to regedit is disabled through GPO
--IJ
0
Get real performance insights from real users

Key features:
- Total Pages Views and Load times
- Top Pages Viewed and Load Times
- Real Time Site Page Build Performance
- Users’ Browser and Platform Performance
- Geographic User Breakdown
- And more

 
LVL 85

Accepted Solution

by:
oBdA earned 2000 total points
ID: 34149398
Just add it to the logon script.
That's, for example, a one-liner in a batch logon script:
reg add "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Styles" /v "MaxScriptStatements" /t REG_DWORD /d 0xFFFFFFFF /f

As VB script, it's a bit longer:

Const HKEY_CURRENT_USER = &h80000001
strComputer = "."
Set objReg = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\default:StdRegProv")
strKeyPath = "Software\Acme\Microsoft\Internet Explorer\Styles"
strValueName = "MaxScriptStatements"
intValue = CLng(&hFFFFFFFF)
objReg.CreateKey HKEY_CURRENT_USER, strKeyPath
objReg.SetDWORDValue HKEY_CURRENT_USER, strKeyPath, strValueName, intValue
Set objReg = Nothing

Open in new window

0
 
LVL 65

Expert Comment

by:RobSampson
ID: 34150404
oBdA is right.  You don't need to deploy the MSI.  All the MSI does is run the registry change that you have mentioned.  Therefore, just use oBdA's code as a Logon script, and you will have applied the patch to all users' HKCU paths.

Regards,

Rob.
0
 
LVL 66

Expert Comment

by:johnb6767
ID: 34151821
Most installations modify prefs and the like on first run, and they have full access to hkcu by default, so that's usually when the erg entries are set....

Might even have a first run from the windows installer when the limited user logs on.....
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: Leon
Software Metering within our group of companies has always been an afterthought until auditing of software and licensing became a pain point. Orchestrator and SCCM metering gave us the answer and it was an exciting process.
Citrix XenApp, Internet Explorer 11 set to Enterprise Mode and using central hosted sites.xml file.
The viewer will learn how to simulate a series of coin tosses with the rand() function and learn how to make these “tosses” depend on a predetermined probability. Flipping Coins in Excel: Enter =RAND() into cell A2: Recalculate the random variable…
The view will learn how to download and install SIMTOOLS and FORMLIST into Excel, how to use SIMTOOLS to generate a Monte Carlo simulation of 30 sales calls, and how to calculate the conditional probability based on the results of the Monte Carlo …

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question