May 15, 200917 yr Hi all,I have created a new bootable CD under WinPE 3.0 and have also created a simple menu (thanks to you all at MSFN) and it works all OK. The only issue I have is that after restoring the image, Ghost exits back to the cmd prompt, and in order to restart the system i need to type in "Exit". Does anyone know what i can do, i have attached the menu screenshot and the ghost command used is~:GHOST32.EXE -clone,MODE=restore,SRC=R:\IMAGE.GHO,dst=1 -sure -quiet -span -FX (now the -rb switch used by ghost will restart the PC, but i want to go back to the main menu- can this be done?) Edited May 15, 200917 yr by ner
May 15, 200917 yr Author the menu code is here:@ECHO OFFCLS:LOOPECHO.SYSTEM RECOVERY KIT MENU V2.0ECHO.ECHO.ECHO A. Start System Recovery Kit - Fully automatedECHO B. Start System Recovery Kit - ManualECHO C. Run ExplorerXPECHO D. Capture Image using Microsoft ImagexECHO E. Apply Image using Microsoft ImagexECHO F. Run Diskpart - 1 partition creation and setup for disk 0ECHO G. Start Backup Recovery - Fully Automated ECHO H. Start Symantec Norton GhostECHO I. Start Symantec Norton Ghost ExplorerECHO Q. Quit MenuECHO.:: SET /P prompts for input and sets the variable:: to whatever the user typesSET Choice=SET /P Choice=Type the letter and press Enter::: The syntax in the next line extracts the substring:: starting at 0 (the beginning) and 1 character longIF NOT '%Choice%'=='' SET Choice=%Choice:~0,1%ECHO.:: /I makes the IF comparison case-insensitiveIF /I '%Choice%'=='A' GOTO ItemAIF /I '%Choice%'=='B' GOTO ItemBIF /I '%Choice%'=='C' GOTO ItemCIF /I '%Choice%'=='D' GOTO ItemDIF /I '%Choice%'=='E' GOTO ItemEIF /I '%Choice%'=='F' GOTO ItemFIF /I '%Choice%'=='G' GOTO ItemGIF /I '%Choice%'=='H' GOTO ItemHIF /I '%Choice%'=='I' GOTO ItemIIF /I '%Choice%'=='Q' GOTO EndECHO "%Choice%" is not valid. Please try again.ECHO.GOTO Loop:ItemARECOVERY32.EXE -clone,MODE=restore,SRC=R:\IMAGE.GHO,dst=1 -sure -quiet -span -RBGOTO Again:ItemBRECOVERY32.EXE GOTO END:ItemCExplorerxp.exe /sGOTO END:ItemDimagex_capture.cmdGOTO END:ItemEimagex_apply.cmdgoto END:ItemfDiskpart.cmdgoto END:ItemGGHOST32.EXE -clone,MODE=restore,SRC=D:\BACKUP.GHO,dst=1 -sure -quiet -span -RBgoto END:ItemHGHOST32.EXEgoto END:ItemIGHOSTexp.EXEgoto END:QUIT:Endsee i have updated the last switch on the ghost command to read -rb and have taken away the -fx - this re-boots the pc OK, but i wanted to go back to the menu, but i get back to the cmd prompt, if i type in "Menu" it works...
May 15, 200917 yr Replace your 'goto END' to 'goto LOOP' where you want to return to your menu.If this menu is running from the Startnet.cmd, add an EXIT command as the last line in startnet.cmd to cause the reboot.
May 15, 200917 yr Replace your 'goto END' to 'goto LOOP' where you want to return to your menu.If this menu is running from the Startnet.cmd, add an EXIT command as the last line in startnet.cmd to cause the reboot.Alternatively, he could also use the Q. option to run 'wpeutil reboot' correct?
May 20, 200917 yr Deleted.My post about PEShutdown is so dated, please ignore it. Edited May 20, 200917 yr by gadget
Create an account or sign in to comment