How to Customize the Sherpya XPE for Your Windows Rescue CD

Customizing Your BartPE Rescue Disk


How to Customize the Sherpya XPE for Your Windows Rescue CD (BartPE Disk)

In my previous article, How to Create an Emergency Windows Rescue CD, I went through how one could create a Windows rescue CD, also known as a BartPE disk, so that you can boot a working Windows system from a CD or DVD drive even if your entire hard disk is inaccessible. In this chapter, I will discuss how you can customize the user interface of the rescue CD so that it looks like and operates more like the normal Windows you are accustomed to. You will also learn how you can add shortcuts to the Start Menu and Desktop for the programs you load into your rescue disk.

If you have not yet gone through the basic steps of creating a BartPE CD, please see the first chapter for more information. As suggested in that chapter, it's best that you use a rewriteable CD or DVD to create your rescue CD, since you can then add new features and customize it without wasting a blank CD/DVD.

How to Move the Taskbar to the Bottom of the Screen in the XPE BartPE Disk

By default, the taskbar in XPE is placed at the top of the screen when it boots up. If you prefer the taskbar at the bottom of the screen, do the following:

  1. Start up an ASCII text editor like Notepad. You can find Notepad in your Accessories folder of the Start menu. If you use Notepad, click the "File" menu followed by the "Open" item on the menu that appears.

  2. Select "All Files" in the "Files of type" entry box, somewhere at the bottom of the Open dialog box that appears. This allows you to see all files in a directory, regardless of their extensions.

  3. Go to your BartPE folder. Double-click on the folder "plugin" to open it. Locate the "XPE" folder and open it. Look for the file named "z_xpe-custom.inf.sample". If you can't find any, see if you can find a "z_xpe_custom.inf" file instead. It is possible that Windows has hidden the extension ".sample" from you.

    Double-click that file to open it in Notepad.

  4. Search for the lines that say:

    ; TaskBar on Top - Autohide
    0x3,"Software\Microsoft\Windows\CurrentVersion\Explorer\StuckRects2","Settings",\
      28,00,00,00,ff,ff,ff,ff,​03,00,00,00,01,00,00,00,​3c,00,00,00,1e,00,00,00,fe,\
      ff,ff,ff,fe,ff,ff,ff,02,​04,00,00,1c,00,00,00

    Change the lines to

    ; TaskBar on Top - Autohide
    ;0x3,"Software\Microsoft\Windows\CurrentVersion\Explorer\StuckRects2","Settings",\
    ; 28,00,00,00,ff,ff,ff,ff,​03,00,00,00,01,00,00,00,3c,​00,00,00,1e,00,00,00,fe,\
    ; ff,ff,ff,fe,ff,ff,ff,02,​04,00,00,1c,00,00,00

    That is, add a semi-colon (";") to the beginning of each line in that block.

  5. Search for the lines that say:

    ; TaskBar on Bottom - No Autohide
    ;0x3,"Software\Microsoft\Windows\CurrentVersion\Explorer\StuckRects2","Settings",\
    ; 28,00,00,00,ff,ff,ff,ff,​02,00,00,00,03,00,00,00,3f,​00,00,00,1e,00,00,00,fe,\
    ; ff,ff,ff,e4,02,00,00,02,​04,00,00,02,03,00,00

    Since we want the taskbar at the bottom of the screen, and we want it to be always visible ("no autohide"), remove the initial semi-colon so that the block now reads:

    ; TaskBar on Bottom - No Autohide
    0x3,"Software\Microsoft\Windows\CurrentVersion\Explorer\StuckRects2","Settings",\
      28,00,00,00,ff,ff,ff,ff,​02,00,00,00,03,00,00,00,3f,​00,00,00,1e,00,00,00,fe,\
      ff,ff,ff,e4,02,00,00,02,​04,00,00,02,03,00,00

    Notice that the descriptive line "; TaskBar on Bottom - No Autohide" still has a semi-colon prefix. This is necessary, since that line is just a comment that tells you the meaning of the series of cryptic numbers that follow. Do not remove the semi-colon in front of that line.

  6. You will need to save the file under a different name if you want XPE to use your changes. If you use Notepad, click the "File" menu followed by the "Save As" menu item. In the dialog box that opens, make sure that you are in the same folder you opened the file originally. Then type the following file name, including the opening and closing quotes, "z_xpe-custom.inf". The opening and closing quotation marks are crucial.

    Note: if Notepad issues a dialog box asking whether you want to replace an existing file, it means you did something wrong. There is no existing file to replace (unless you have done this before). Copy and paste the name that I gave in the paragraph above, including the quotation marks.

  7. Do not close your editor (Notepad or otherwise) yet. We will need it for the other changes as well.

How to Change the Default Screen Resolution

By default, the screen resolution is set to 1024x768. If you are using a small monitor, and prefer it to have a resolution of 800x600, search for following lines in the same file you opened earlier:

; Screen Resolution 1024x768 32bpp
0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.BitsPerPel",​0x020
0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.XResolution",​0x400
0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.YResolution",​0x300

Change it to:

; Screen Resolution 1024x768 32bpp
;0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.BitsPerPel",​0x020
;0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.XResolution",​0x400
;0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.YResolution",​0x300

In other words, prefix a semi-colon to each line in that block the way you did earlier. Then search for the block that looks like the following:

; Screen Resolution 800x600 32bpp
;0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.BitsPerPel",​0x020
;0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.XResolution",​0x320
;0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.YResolution",​0x258

Once again, to activate the lines, remove the comment marker. That is, change it to:

; Screen Resolution 800x600 32bpp
0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.BitsPerPel",​0x020
0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.XResolution",​0x320
0x4,​"ControlSet001\Services\VgaSave\Device0",​"DefaultSettings.YResolution",​0x258

Note that this section only applies to lowering your resolution to 800x600 from the default 1024x768. If your rescue disk boots up with a 640x480 resolution, it means that the Windows system on your rescue disk does not have the drivers for your video monitor. Modifying the above section in such a case will not help you, since in the absence of a driver, Windows uses its pathetic 16 colour 640x480 VGA driver.

How to Change the Words "Starting Windows XPE [The Horse Power]"

When your BartPE rescue disk starts up, and XPE begins loading, a box showing the words "Starting Windows XPE [The Horse Power]..." is displayed. If the words grate on your nerves, search for them in the same file, and modify it to something that you prefer. For example, just delete the words "[The Horse Power]" if that is what irritates you.

Saving the Configuration File

If you have not saved the file after your changes, do so now. You can close the file (quit Notepad), since the next few customizations do not require this particular configuration file.

How to Add Start Menu Shortcuts in XPE

Adding new start menu shortcuts involves going into the configuration files for the particular plugin and modifying them. Since I don't know which plugin you will be modifying, I will use the Drive Snapshot plugin as an example.

Your BartPE folder contains the Snapshot plugin by default. If you have followed my guide to create your rescue disk, you would probably have disabled this plugin, since that trial copy of Drive Snapshot, a commercial hard disk backup and imaging program, has expired.

For the purpose of this tutorial however, I will use that plugin as an example since the program is extremely easy to configure for (and thus to explain in a tutorial like this), and comes by default with all BartPE installations. The software is also a very useful tool for a rescue disk, since you can use it to backup (or image) your hard disk and restore it in an emergency. Even if you are not buying it for your system, you can use this procedure as a model to add Start Menu shortcuts for your other programs.

  1. Go into your "plugins" folder and locate the "snapshot" folder. Using an ASCII text editor like Notepad, open the "snapshot.inf" file. You may have difficulty locating the correct file if your Windows has been configured not to show file extensions, since all the files will appear to you to be called "snapshot". If so, please see my article on how to force Explorer to display the file extensions for a solution.

  2. Locate the line that says "Enable=0" and change it to "Enable=1". If it's already at "Enable=1", leave it alone.

  3. Go to the end of the file and add the following lines.

    [Software.AddReg]
    0x2,​"Sherpya\XPEinit\Programs",​"Drive Snapshot",​"%SystemDrive%\Programs\snapshot\snapshot.exe"

    This line adds an entry called "Drive Snapshot" to the Programs menu on your rescue disk's Start menu. When you click this entry, the program at "%SystemDrive%\Programs\snapshot\snapshot.exe" will be run.

Explanation of the Components

How to Add Desktop Shortcuts

I will continue to use the Drive Snapshot program as an illustration. Add the following line immediately after the two lines you added in the previous section:

0x2,​"Sherpya\XPEinit\Desktop",​"Drive Snapshot",​"%SystemDrive%\Programs\snapshot\snapshot.exe"

That is, it should now read:

[Software.AddReg]
0x2,​"Sherpya\XPEinit\Programs",​"Drive Snapshot",​"%SystemDrive%\Programs\snapshot\snapshot.exe"
0x2,​"Sherpya\XPEinit\Desktop",​"Drive Snapshot",​"%SystemDrive%\Programs\snapshot\snapshot.exe"

The new line adds another registry item, this time to specify the desktop shortcut for the program. It follows basically the same principles as the one we have seen for the Start menu. "Drive Snapshot" is the name of the icon that will be displayed on the desktop for you to click on. When you double-click that icon, the program "%SystemDrive%\Programs\snapshot\snapshot.exe" will be executed.

Again, to add your own desktop icons for your programs, just substitute those two parameters for the appropriate ones.

Conclusion

With this information, you should be able to further customize your BartPE Windows rescue disk so that the rescue environment will be suitable for the kind of things you want to do with it.

Copyright © 2008-2015 by Christopher Heng. All rights reserved. Get more "How To" guides and tutorials from https://www.howtohaven.com/.

This article can be found at https://www.howtohaven.com/system/customize-windows-xpe-rescue-cd.shtml

howtohaven™ Site News Feed

Do you find this article useful? You can learn of new articles and scripts that are published on howtohaven.com by subscribing to the RSS newsfeed. Simply point your newsfeed reader or a browser that supports RSS feeds at https://www.howtohaven.com/howtohaven.xml.


Please Do Not Reprint This Article

This article is copyrighted. Please do not reproduce this article in whole or part, in any form, without obtaining my written permission.

Related Pages

Newest Pages

How to Link to This Page

It will appear on your page as:

How to Customize the Sherpya XPE for Your Windows Rescue CD (BartPE Disk)


thesitewizard.com: Free Webmaster Tutorials, Scripts and Articles

thefreecountry.com: Free Programmers' Resources, Free Webmasters' Resources, Free Security Resources, Free Software

HowToHaven.com: Free How-To Guides
If you find this site useful, please link to us.