Page 1 of 1
How to get Run/RunOnce keys working?
#1
Posted 16 March 2008 - 02:51 PM
I can add the keys fine after Vista is installed, but if I add them in during setup they're wiped clean before the first user logs on.
the HKCU RunOnce branch is actually removed in it's entirety. but it works fine if I add the key manually after the user logs on.
the HKCU RunOnce branch is actually removed in it's entirety. but it works fine if I add the key manually after the user logs on.
#2
Posted 17 March 2008 - 01:47 AM
woot! got it working. HKCU Run & RunOnce were being obliterated before first logon (even when I locked down permissions on them beforehand), but HKLM RunOnce stays intact.
so I used HKLM RunOnce to run a script that adds a key to HKCU RunOnce and then reboots.
I needed to use both because certain pesky registry tweaks will only "stick" if run from HKCU, while others only "stick" when run from HKLM.
Had to combine setupcomplete.cmd with the RunOnce keys to finally set all the keys I wanted.
specialize, oobeSystem, and even auditUser passes were all (mostly) worthless.
(this was all with SP1 RTM btw)
P.S. - Another thing I noticed early on, you can't use regedit to import the Run\RunOnce keys, they won't be written. Instead I used reg add or regini. I never tried reg import.
so I used HKLM RunOnce to run a script that adds a key to HKCU RunOnce and then reboots.
I needed to use both because certain pesky registry tweaks will only "stick" if run from HKCU, while others only "stick" when run from HKLM.
Had to combine setupcomplete.cmd with the RunOnce keys to finally set all the keys I wanted.
specialize, oobeSystem, and even auditUser passes were all (mostly) worthless.
(this was all with SP1 RTM btw)
P.S. - Another thing I noticed early on, you can't use regedit to import the Run\RunOnce keys, they won't be written. Instead I used reg add or regini. I never tried reg import.
This post has been edited by [TiLT]: 17 March 2008 - 01:53 AM
#3
Posted 17 March 2008 - 02:15 AM
[TiLT], on Mar 17 2008, 05:47 PM, said:
woot! got it working. HKCU Run & RunOnce were being obliterated before first logon (even when I locked down permissions on them beforehand), but HKLM RunOnce stays intact.
so I used HKLM RunOnce to run a script that adds a key to HKCU RunOnce and then reboots.
I needed to use both because certain pesky registry tweaks will only "stick" if run from HKCU, while others only "stick" when run from HKLM.
Had to combine setupcomplete.cmd with the RunOnce keys to finally set all the keys I wanted.
specialize, oobeSystem, and even auditUser passes were all (mostly) worthless.
(this was all with SP1 RTM btw)
P.S. - Another thing I noticed early on, you can't use regedit to import the Run\RunOnce keys, they won't be written. Instead I used reg add or regini. I never tried reg import.
so I used HKLM RunOnce to run a script that adds a key to HKCU RunOnce and then reboots.
I needed to use both because certain pesky registry tweaks will only "stick" if run from HKCU, while others only "stick" when run from HKLM.
Had to combine setupcomplete.cmd with the RunOnce keys to finally set all the keys I wanted.
specialize, oobeSystem, and even auditUser passes were all (mostly) worthless.
(this was all with SP1 RTM btw)
P.S. - Another thing I noticed early on, you can't use regedit to import the Run\RunOnce keys, they won't be written. Instead I used reg add or regini. I never tried reg import.
Glad ya got it workin..how about a tute for the few not in the know?
#4
Posted 17 March 2008 - 02:53 AM
use Windows\Setup\Scripts\setupcomplete.cmd to "reg add" runonce.cmd to the HKLM RunOnce
runonce.cmd then sets the HKCU RunOnce cmd that I want via "reg add" and reboots via shutdown /r.
I run all .cmd with hidec and they work fine that way.
Edit: You may be able to set the HKLM RunOnce key at another time in your unattended.xml too, but that's how I did it since I was using setupcomplete.cmd already. Hidec also works fine for batch files executed from your unattended.xml
runonce.cmd then sets the HKCU RunOnce cmd that I want via "reg add" and reboots via shutdown /r.
I run all .cmd with hidec and they work fine that way.
Edit: You may be able to set the HKLM RunOnce key at another time in your unattended.xml too, but that's how I did it since I was using setupcomplete.cmd already. Hidec also works fine for batch files executed from your unattended.xml
This post has been edited by [TiLT]: 17 March 2008 - 03:02 AM
#5
Posted 17 March 2008 - 04:20 AM
[TiLT], on Mar 17 2008, 07:53 PM, said:
use Windows\Setup\Scripts\setupcomplete.cmd to "reg add" runonce.cmd to the HKLM RunOnce
runonce.cmd then sets the HKCU RunOnce cmd that I want via "reg add" and reboots via shutdown /r.
I run all .cmd with hidec and they work fine that way.
Edit: You may be able to set the HKLM RunOnce key at another time in your unattended.xml too, but that's how I did it since I was using setupcomplete.cmd already. Hidec also works fine for batch files executed from your unattended.xml
runonce.cmd then sets the HKCU RunOnce cmd that I want via "reg add" and reboots via shutdown /r.
I run all .cmd with hidec and they work fine that way.
Edit: You may be able to set the HKLM RunOnce key at another time in your unattended.xml too, but that's how I did it since I was using setupcomplete.cmd already. Hidec also works fine for batch files executed from your unattended.xml
Look I know where you are coming from but a simple tutorial would be helpful to some.
#6
Posted 17 March 2008 - 08:43 PM
MAVERICKS CHOICE, on Mar 17 2008, 04:20 AM, said:
[TiLT], on Mar 17 2008, 07:53 PM, said:
use Windows\Setup\Scripts\setupcomplete.cmd to "reg add" runonce.cmd to the HKLM RunOnce
runonce.cmd then sets the HKCU RunOnce cmd that I want via "reg add" and reboots via shutdown /r.
I run all .cmd with hidec and they work fine that way.
Edit: You may be able to set the HKLM RunOnce key at another time in your unattended.xml too, but that's how I did it since I was using setupcomplete.cmd already. Hidec also works fine for batch files executed from your unattended.xml
runonce.cmd then sets the HKCU RunOnce cmd that I want via "reg add" and reboots via shutdown /r.
I run all .cmd with hidec and they work fine that way.
Edit: You may be able to set the HKLM RunOnce key at another time in your unattended.xml too, but that's how I did it since I was using setupcomplete.cmd already. Hidec also works fine for batch files executed from your unattended.xml
Look I know where you are coming from but a simple tutorial would be helpful to some.
that would be nice. i don't have the time to try it right now. I use FirstLogonCommanfs for now and works great. Im now into SP1 without any hassles.
- ← Best pass for applying registry tweaks?
- Unattended Windows Vista/Server 2008
- Req the registry tweak for the following... →
Share this topic:
Page 1 of 1



Help
Back to top









