Skip to content Skip to main navigation Skip to footer

Rebooting the System after Imaging or Restoring in BartPE

Important Note: BartPE is obsolete. The BartPE environment is based on Windows XP and may not build or function correctly on current/newer systems. Additionally, the Bart PE Builder program and documentation is no longer available from its original source. Using TBWinRE or TBWinPE is recommended.

If you are running Image for Windows within BartPE and have found that the /rb command line switch does not work on your system, here is an alternative.  After creating the BartPE plugin, locate the file named autorun_ifwv2.cmd, and change its content to the following:

@echo off
Title IFW V2 AutoRun
start "" /wait /D%~d0\programs\ifwv2 %~d0\programs\ifwv2\imagew.exe
@%systemroot%\system32\nu2shell.exe -r

The code above adds the /wait parameter to the imagew.exe command line, which forces the script to wait until Image for Windows exits before reading the next line in the script.  Also new is the nu2shell.exe -r line, which will reboot the system after imagew.exe has finished running.

Was This Article Helpful?