Worf Posted January 22, 2006 Share Posted January 22, 2006 Hi.I seem to be having problems with the RunOnceEX.cmd not runnning on the first login.When windows finnishes installing it will reboot and windows will load, but once loaded and logged in it does not start the RunOnceEx to start installing my applications. If i reboot windows and login again RunOnceEx will start and install my applications. I have the RunOnceEx.cmd in $OEM$/$1/install directory and it is called using WinNT.sif in the 386 directory using the following line. [GuiRunOnce]%systemdrive%\install\RunOnceEx.cmdAny one have any idea what the problem might be?Many ThanksWorf Link to comment Share on other sites More sharing options...
muiz Posted January 22, 2006 Share Posted January 22, 2006 (edited) You might want to read this again http://unattended.msfn.org/unattended.xp/view/web/31/This is what you did : [GuiRunOnce]%systemdrive%\install\RunOnceEx.cmdThis is how it should be :First of all, remove the [GuiRunOnce] entries in winnt.sif, as RunOnceEx can be used to replace [GuiRunOnce] completely. Although you can use both if needed for some reason, but they will both run at the same time, so use caution.To start RunOnceEx on first logon, we will need to import the registry keys during GUI-mode of Windows Setup. We can do this by using cmdlines.txt which executes a series of commands during the T-12 minute stage of Windows XP Setup. Create a cmdlines.txt file in Notepad and paste in the following:[COMMANDS]"RunOnceEx.cmd"Save this as cmdlines.txt inside the $OEM$ folder within your Windows Setup Source folder. If there currently isn't one created, create one. While we're on the subject, feel free to read about the Edited January 22, 2006 by muiz Link to comment Share on other sites More sharing options...
Worf Posted January 23, 2006 Author Share Posted January 23, 2006 Thanks for the reply. I have done this but for some reason windows sticks when it gets to registering components. Can you have more than one line in the cmdlines.txt? Link to comment Share on other sites More sharing options...
jondercik Posted January 24, 2006 Share Posted January 24, 2006 yes you can. Link to comment Share on other sites More sharing options...
eyeball Posted January 24, 2006 Share Posted January 24, 2006 post your cmdlines.txt and your runonce and maybe we can help Link to comment Share on other sites More sharing options...
cluberti Posted January 24, 2006 Share Posted January 24, 2006 I'm not sure there's a technical problem here. You're using the [GuiRunOnce] section to run your .cmd file, that enters your registry settings for doing the RunOnce installation. If what you are saying is correct (it takes a second reboot to get the apps to start installing), this is expected behavior. From the description of GuiRunOnce in the Windows 2000 Resource Kit:The [GuiRunOnce]section of the answer file contains a list of commands that run the first time a user logs on to the computer after Setup runs.So, after your setup finishes, your computer is logged on, the .cmd file is run (importing the registry settings in your runonceex.cmd file to configure RunOnceEx), and then the next time the machine is rebooted and logged on, these registry settings are read in and installation begins. This is how it is supposed to be working.Perhaps try running your RunOnceEx.cmd file from [setupParams], so that it is imported BEFORE the first reboot, not AFTER. Link to comment Share on other sites More sharing options...
Worf Posted January 24, 2006 Author Share Posted January 24, 2006 Hi here is a copy of my cmdlines.txt and RunOnceEx.cmd files eyeball.Thankyou for you offer to help, and also to you all.CmdLines.txt. [COMMANDS]"useraccounts.cmd""RunOnceEx.cmd"RunOnceEx.cmdcmdow @ /HID@echo offIF EXIST D:\CD.TXT SET CDROM=D:IF EXIST E:\CD.TXT SET CDROM=E:IF EXIST F:\CD.TXT SET CDROM=F:IF EXIST G:\CD.TXT SET CDROM=G:IF EXIST H:\CD.TXT SET CDROM=H:IF EXIST I:\CD.TXT SET CDROM=I:IF EXIST J:\CD.TXT SET CDROM=J:IF EXIST K:\CD.TXT SET CDROM=K:IF EXIST L:\CD.TXT SET CDROM=L:IF EXIST M:\CD.TXT SET CDROM=M:IF EXIST N:\CD.TXT SET CDROM=N:IF EXIST O:\CD.TXT SET CDROM=O:IF EXIST P:\CD.TXT SET CDROM=P:IF EXIST Q:\CD.TXT SET CDROM=Q:IF EXIST R:\CD.TXT SET CDROM=R:IF EXIST S:\CD.TXT SET CDROM=S:IF EXIST T:\CD.TXT SET CDROM=T:IF EXIST U:\CD.TXT SET CDROM=U:IF EXIST V:\CD.TXT SET CDROM=V:IF EXIST W:\CD.TXT SET CDROM=W:REG ADD %KEY% /V TITLE /D "Installing Applications And Other Files" /f; User Information; Installing Applications And Other Files.REG ADD %KEY%\001 /VE /D "Over the next few minutes you will see automated installations"/fREG ADD %KEY%\001 /VE /D "of various software applications, windows updates, and registry tweaks" /fREG ADD %KEY%\001 /VE /D "being implemented. The computer will restart automatically" /fREG ADD %KEY%\001 /VE /D "once the whole process has finished!" /fREG ADD %KEY%\001 /VE /D " " /f; Applications To Install; WinZip 10REG ADD %KEY%\005 /VE /D "WinZip 10" /fREG ADD %KEY%\005 /V 1 /D "%CDROM%\Software\WinZip\SETUP.exe /autoinstall /noqp" /fREG ADD %KEY%\005 /V 2 /D "REGEDIT /S %CDROM%\Software\WinZip\Reg.reg" /f; WinRARREG ADD %KEY%\006 /VE /D "WinRAR" /fREG ADD %KEY%\006 /V 1 /D "%CDROM%\Software\WinRAR\Wrar35.exe /s" /f;Install Reg TweaksREG ADD %KEY%\080 /VE /D "Importing Registry Tweaks" /fREG ADD %KEY%\080 /V 1 /D "REGEDIT /S %CDROM%\Regtweaks\Regtweaks.reg" /f; Finding And Moveing My DocumentsREG ADD %KEY%\100 /VE /D "Finding And Moving My Documents Folder"For %%a in (D E F G H I J K L M N O P Q R S T U V W X Y Z) DO IF EXIST %%a:\My Documents set MYDOC=%%a:\My DocumentsREG ADD HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders /v Personal /t REG_SZ /d "%MYDOCS%" /f; Cleaning Up And RebootingREG ADD %KEY%\085 /VE /D "Cleaning Up And Rebooting" /fREG ADD %KEY%\085 /V 1 /D "cleanup.cmd" /fEXITAgain thank you allRegardsWorf Link to comment Share on other sites More sharing options...
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