Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Registry mod via Group Policy 6

Status
Not open for further replies.

spiego

MIS
Aug 16, 2004
80
US
Is it possible to modify the registry to a client's computer via Group Policy? If so, how? I want to add a value to the following entry:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Exchange\Client\Options

TIA
 
Here's the VBScript code that you'll need.

'begin script
Dim objShell
On error resume next
''''''''''''''
' Registry key
''''''''''''''
strRegLoc = "HKEY_LOCAL_MACHINE\SOFTWARE\_
Microsoft\Exchange\Client\Options"
strKey = "<keyname>"
strValue = "<value>"
''''''''''''''''''''''''
'write new key and value
''''''''''''''''''''''''
Set objShell = CreateObject("WScript.Shell")

objShell.RegWrite strRegLoc & strKey, 1, "REG_SZ"
objShell.RegWrite strRegLoc & strKey,_
strValueLocal, "REG_SZ"
'end script

Obviously, you'll need to enter your key name and value into the given script.

Then, create a new GPO, remove all administrative templates for faster policy processing. Go to the scripts section under the desired node (user or machine). Add this new logon or startup script. You'll need to place the .vbs file into its respective GPO directory.

Hope This Helps,

Good Luck!
 
Oops...the last part of the script where is states

strValueLocal

should state

strValue

Hope This Helps,

Good Luck!
 
Mark,
Are you feeling okay? I thought I just heard you say that there is a way to do something without the need for scripting....Having a bad day with a script? Something we can help you with? Don't want your scripting knowledge to stop teaching us "fresh" ones easier ways of doing complex things.....
 
After Mark suggested it i gave it a try and was very impressed, i suspect MS were impressed as well because they bought the company.





When you are the IT director, it's your job to make sure the IT works. If it does work they know already and if it doesn't, they don't want to hear your pathetic excuses.
 
It's kinda funny that Microsoft missed this one while developing the GPMC. I would think this is a fairly common task to need reg mods via Group Policy. Maybe they are purposely leaving these little gold nuggets for others to capitalize on?
 
I think that it was missed when 2000 first came out with AD. After that the 3rd party tool was already out there and then adding it to GPMC would have been killing the competition or beating down the little guy.

In the end, the "little guy" made a LOT of money on this tool and got to join MS as an Exec. Not too shabby!

I hope you find this post helpful.

Regards,

Mark

Check out my scripting solutions at
 
Mark,

Thanks for tip. I installed it and it works just like I had hoped.
 
Duck Mark it's like some ninja has you in his sights :)





When you are the IT director, it's your job to make sure the IT works. If it does work they know already and if it doesn't, they don't want to hear your pathetic excuses.
 
pointlaugh.gif
rofl.gif


LOL now that was FUNNY. Glad you guys like the tool. I thought it was sharp too.

So to protect my reputation as a scriptaholic, that tool is really awesome for adding scripts to the RunOnce section of the registry. ;-)

I hope you find this post helpful.

Regards,

Mark

Check out my scripting solutions at
 
PHEW reputation restored we were all sweating.

Nice one.





When you are the IT director, it's your job to make sure the IT works. If it does work they know already and if it doesn't, they don't want to hear your pathetic excuses.
 
I know I was! 58sniper, I got your back on the "million stars for Mark" campaign!

porkchopexpress,
That was very funny. I'm giving you a star just for the hilarity!

 
ha i've flushed out the ninja it's tfg13 ... pulls of mask Scooby Doo style





When you are the IT director, it's your job to make sure the IT works. If it does work they know already and if it doesn't, they don't want to hear your pathetic excuses.
 
Hey I like this campaign. After traveling for 3 weeks I found my name missing from most of the forums I held top MVP for for the past 2 years. Now that hurts!

I hope you find this post helpful.

Regards,

Mark

Check out my scripting solutions at
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top