August 18, 200422 yr I have 2 batch file..first_boot.cmdCLS@echo offECHO.ECHO Removing Wallpapers and Screensavers...DEL "%systemroot%\*.bmp"DEL "%systemroot%\Web\Wallpaper\*.jpg"DEL "%systemroot%\system32\dllcache\*.scr"DEL "%systemroot%\system32\*.scr"ECHO.ECHO Removing useless shortcuts...DEL "%systemdrive%\Documents and Settings\All Users\Start Menu\Windows Update.lnk"DEL "%systemdrive%\Documents and Settings\All Users\Start Menu\Set Program Access and Defaults.lnk"DEL "%systemdrive%\Documents and Settings\All Users\Start Menu\Windows Catalog.lnk"ECHO.ECHO Applying Registry Tweaks...REGEDIT /S %systemdrive%\install\RegTweaks.regECHO.ECHO Copying patched UXTheme.dll...REN %systemroot%\System32\uxtheme.dll uxtheme.oldCOPY "%systemdrive%\Install\uxtheme\uxtheme.dll" "%systemroot%\System32\"ECHO.ECHO Copying PSKill.exe...COPY "%systemdrive%\Install\Tools\pskill.exe" "%systemroot%"CLS@ECHO OFFECHO.ECHO Ejecting CD-ROM Drives...ECHO If you are using a cd rom please remove it fromECHO the cdrom drive and If you have a second cd placeECHO it in the drive at this time please.ECHO.ECHO If you are using a dvd please remove itECHO at this time.ECHO.ECHO Wait till the cdrom/dvd drive quits blinkingECHO and then ...start cscript %systemdrive%\install\Tools\cd_eject.vbs >nullPSKill cscript.exe >nullECHO.PAUSEIF EXIST %systemdrive%\install\applications.cmd GOTO APPSSET CDROM2=IF EXIST D:\install\applications.cmd SET CDROM2=D:IF EXIST E:\install\applications.cmd SET CDROM2=E:IF EXIST F:\install\applications.cmd SET CDROM2=F:IF EXIST G:\install\applications.cmd SET CDROM2=G:IF EXIST H:\install\applications.cmd SET CDROM2=H:IF EXIST I:\install\applications.cmd SET CDROM2=I:IF EXIST J:\install\applications.cmd SET CDROM2=J:IF EXIST K:\install\applications.cmd SET CDROM2=K:IF NOT EXIST %CDROM2%\install\applications.cmd GOTO APPS:APPSECHO Running Applications Batch ...ECHO.start /wait %CDROM2%\install\applications.cmdECHO Moving programs shortcuts ...ECHO.MOVE /y "%systemdrive%\Documents and Settings\All Users\Desktop\*.lnk" "%systemdrive%\Documents and Settings\All Users\Desktop\Programs\"ECHO.ECHO Deleting Temp Installation Files...RD /S /Q %systemdrive%\InstallRD /S /Q %systemdrive%\DriversECHO.ECHO Restarting the PC in 1 minute...shutdown.exe -r -f -t 60 -c "Windows XP will now restart in 1 minute, this will give enough time for the shortcuts to update and for the shell to fully load before its ready to restart!"EXITand applications.cmd (Second CD)CLS@echo offECHO.ECHO Installing Office 2003 Professional Hebrew EditionECHO Please wait...start /wait %CDROM2%\install\Applications\Office2003\setup.exe TRANSFORMS=Unattended.MST /qb-ECHO.ECHO Installing ICQ Lite 4.0 Build #1646 + PatchECHO Please wait...start /wait %CDROM2%\install\Applications\IcqLite4\icq4.exe /Spskill icqlite.exeECHO.ECHO Installing Ad-Aware SE Personal Build 1.03ECHO Please wait...start /wait %CDROM2%\install\Applications\AdAwareSE\Adaware-SE.msi /passive /npskill Adaware.exepskill hh.exepskill Ad-Aware.exeECHO.ECHO Installing Daemon Tools 3.33ECHO Please wait...start /wait %CDROM2%\install\Applications\DaemonTools\daemon.msi /q /passive /norestartECHO.ECHO Installing DivX 5.2ECHO Please wait...start /wait %CDROM2%\install\Applications\DivX52\DivX52.exe /SECHO.ECHO Installing FlashGet 1.60aECHO Please wait...start /wait %CDROM2%\install\Applications\FlashGet160\fgf160a.exe /SECHO.ECHO Installing FlashFXP 3.0 FinalECHO Please wait...start /wait %CDROM2%\install\Applications\FlashFxp3\FlashFXP30.exe /SilentECHO.ECHO Registering FlashFXP 3.0 FinalECHO Please wait...copy /y "%CDROM2%\install\Applications\FlashFxp3\flashfxp.key" "%systemdrive%\Progra~1\FlashFXP\"ECHO.ECHO Installing Ahead Nero Burning Rom 6.3ECHO Please wait...start /wait %CDROM2%\install\Applications\Nero6\nero63117.exe /silent /norebootECHO.ECHO Registering Ahead Nero Burning Rom 6.3ECHO Please wait...REGEDIT /S %CDROM2%\install\Applications\Nero6\regnero.regECHO.ECHO Installing WinRar 3.40 Beta 4ECHO Please wait...start /wait %CDROM2%\install\Applications\WinRar34b4\wrar34b4.exe /sECHO.ECHO Installing UltraISO 7.21 SR-2ECHO Please wait...start /wait %CDROM2%\install\Applications\UltraISO7\uiso7_me.exe /VERYSILENT /SP-ECHO.ECHO Registering UltraISO 7.21 SR-2ECHO Please wait...REGEDIT /S %CDROM2%\install\Applications\UltraISO7\reg.regECHO.ECHO Installing Serv-U 5.1ECHO Please wait...start /wait %CDROM2%\install\Applications\ServU51\susetup.exe /spskill servua~1.exepskill servut~1.exeECHO.ECHO Registering Serv-U 5.1ECHO Please wait...copy /y "%CDROM2%\install\Applications\ServU51\ServUCert.key" "%systemdrive%\Progra~1\Serv-U\"EXITThe problem is that when its done do applications.cmd batch its done and dont do last commands in first_boot.cmd, This commands:ECHO Moving programs shortcuts ...ECHO.MOVE /y "%systemdrive%\Documents and Settings\All Users\Desktop\*.lnk" "%systemdrive%\Documents and Settings\All Users\Desktop\Programs\"ECHO.ECHO Deleting Temp Installation Files...RD /S /Q %systemdrive%\InstallRD /S /Q %systemdrive%\DriversECHO.ECHO Restarting the PC in 1 minute...shutdown.exe -r -f -t 60 -c "Windows XP will now restart in 1 minute, this will give enough time for the shortcuts to update and for the shell to fully load before its ready to restart!"EXITHmm whats problem?
August 18, 200422 yr first of all u need remove the - " that u put after the *.ink" and the one b4 the move path like this :MOVE /y "%systemdrive%\Documents and Settings\All Users\Desktop\*.lnk %systemdrive%\Documents and Settings\All Users\Desktop\Programs\"second, with RD command u can't remove a full folder, u can only remove anempty folder with RD command.
August 18, 200422 yr second, with RD command u can't remove a full folder, u can only remove anempty folder with RD command.ummm, no lol RD /S /Q "path\to\folder" it doesnt care whats in the folder, it will remove it
August 18, 200422 yr Author I check and my command about Moving programs shortcuts works fine... and the Deleting Temp Installation Files works too (I check single command)...
August 18, 200422 yr RD /S /Q %systemdrive%\Install should be the last command executed in your batch, especially if your batch files are in the install directory otherwise any commands after that will not be executed because the batch file has been deleted...
August 18, 200422 yr Author hmmm u dont understand me..the command good and work but after applications.cmd its exit to desktop and dont do the command the after applications.cmd ..
August 18, 200422 yr Have you tried removing the EXIT from the applications.cmd?I normally just do a CALL <CMD FILE>. Maybe you should try that.
Create an account or sign in to comment