VBS or BAT to update the local registry on domain pc run by poweruser
Posted on 2008-10-15
VBS or BAT to update the local registry on domain pc run by poweruser.
I am trying to create a bat or vbs script to that a designated poweruser can run on a Domain Users machine to edit the registry. The Domain Users account have been locked down with Group Policy so I am using the 'runas' command so johndoe (the poweruser, who as admin priv on every machine) can execute the script and update the registry key. I have two files, the first is a batch file as shown below with one line and the second is the .reg file to alter the registry. The script HAS TO BE RUN while the current domain user is logged on the change the key. I keep getting directory doesn't exist errors. Could someone please help me?
runas /profile /env /user:thedomain\johndoe "regedit \"\\DC01\Shared Folder\Scripts\FixIE\FixIE.reg\""
Windows Registry Editor Version 5.00