CompMaster Posted August 14, 2005 Posted August 14, 2005 (edited) I have cmd file right now and its intalling programs.... lets call it 1.cmdnow.... what I want to do is when 1.cmd finishes I want the computer to restart... and after that I want that 2.cmd will restart its files....orto write a command that in some point of the 1.cmd file the comp. will restart and after the restart it will continue the file....this is very important question and can help me much.... Edited August 14, 2005 by CompMaster
Sonic Posted August 14, 2005 Posted August 14, 2005 You must place your cmd in the RunOnceEx registry key ... in each file you set the next cmd to execute ... for reboot use "shutdown -r -t xx" (where xx are the seconds)Goodbye.
CompMaster Posted August 14, 2005 Author Posted August 14, 2005 RunOnceEx registry key ?can you give me an example please? (I'm new in all of this)
jbm Posted August 14, 2005 Posted August 14, 2005 this is a page from the unattended guide that explains about runonceexhttp://unattended.msfn.org/intermediate/me...s/runonceex.htm
maxXPsoft Posted August 14, 2005 Posted August 14, 2005 (edited) hmm, It don't have to be RunoncEX Heres what I do to start something after the reboot.In this example I'm opening the Fonts folder which register's the Fonts I have added.Shouldn't be too hard to modify that to call your *.cmd fileJust add it to your cleanup.cmd right before the ShutdownNOTICE: Its not RunoncEX but simply Runonce I have experimented and added like 10 things there as a test, all work just fine as long as they are correct Path's. This also goes to the Current User and can be applied to other Users.REG ADD HKCU\Software\Microsoft\Windows\CurrentVersion\Runonce /V RegisterFonts /D "%SystemRoot%\explorer.exe /e,/root,%systemroot%\Fonts"BTW, The reason I don't use Runoncex is I have had occasions where certain software added something there and i don't want to Jack with it...Bing Bada Boom Edited August 14, 2005 by maxXPsoft
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now