Export (0) Print
Expand All

How to: Create the Windows Installer Package for 32-bit Client Computers

Published: December 17, 2010

Updated: October 9, 2012

Applies To: Windows Home Server 2011, Windows Server 2012 Essentials, Windows Small Business Server 2011 Essentials, Windows Storage Server 2008 R2 Essentials

Before you start the procedure in this section, you must complete the procedures listed in How to: Install the Windows Installer XML (WiX) Tools and How to: Create the Windows Installer Package for the Server.

After you download and install the tools, you can use them to create the Windows Installer package (.msi) files. An add-in can contain code that is installed on the server, on client computers, or on both the server and client computers.

The Deployment sample that is provided with the SDK is configured to install a new top-level tab, install an XML file that extends the home page on the server, and install the XML files that are used to extend the Launchpad on both a 32-bit client computer and a 64-bit client computer. Because of the configuration settings that are required, separate Windows Installer packages must be created if you are extending the Launchpad for both 32-bit and 64-bit client computers. For more information about extending the Launchpad, see Creating a Launchpad Add-In

The following procedure shows you how to create a Windows Installer package that is used to install the code from the sample that runs on a 32-bit client computer.

The example for the server shows the installation of multiple files. This example shows the installation of one file on the client computer, but the add-in could install multiple files on the client computer. In the sample, the same source file is used for 32-bit and 64-bit client computers, but separate .msi files are needed because of configuration settings that are specific to the processor architecture.

To create the Windows Installer package

  1. Open Notepad.

  2. Add the following XML code:

    <?xml version='1.0' encoding='windows-1252'?>
    <Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'>
         Name='Sample 32-bit Launchpad Add-in Deployment' 
         Manufacturer='Your Company Name'>
            Description="Sample 32-bit Launchpad Deployment"
            Comments='Sample 32-bit Launchpad Deployment' 
            Manufacturer='Your Company Name'
            SummaryCodepage='1252' />
          <Media Id='1' Cabinet='WSSSampleAddins.cab' EmbedCab='yes' DiskPrompt="CD-ROM #1" />
          <Property Id='DiskPrompt' Value="32-bit Launchpad Installation [1]" />
          <Directory Id='TARGETDIR' Name='SourceDir'>
             <Directory Id='ProgramFilesFolder' Name='PFiles'>
                <Directory Id="WindowsServerDir" Name="Windows Server">
                   <Directory Id="WindowsServerBinDir" Name="Bin">
                      <Directory Id="WindowsServerLaunchPadDir" Name="Launchpad">
                         <Component Id='LaunchPadComponent' Guid='d21da776-83F1-4F22-985B-FDB3C8ABE491'>
          <Feature Id='Complete' Level='1'>
             <ComponentRef Id='LaunchPadComponent' />
    • Each Id attribute and Guid attribute for the components must be unique.

    • The Name attribute of the File element is the name of the file that is copied to the specified folder on the target computer.

    • The Source attribute of the File element is the relative path to the file.

    • The difference between installing files on a 32-bit client computer and a 64-bit client computer is the settings are not needed for the processor architecture, and the Id attributes of the parent folders are not the same. For 32-bit client computers, the Id attribute is ProgramFilesFolder; for 64-bit client computers, the Id attribute is ProgramFiles64Folder.

  3. Save the file as SampleWSSClientDeployment32.wxs. When developing .msi files other than the sample, you can provide any name, but the file must have a .wxs extension.

  4. Create the .wixobj file from the file that you created in the previous step by using the Candle tool from the WiX toolset. Open a command-prompt window and type the following command followed by Enter:

    candle.exe SampleWSSClientDeployment32.wxs

  5. Create the .msi file from the .wixobj file by running the Light tool from the WiX toolset. In the command-prompt window, type the following command followed by Enter:

    light.exe -ext WixUIExtension SampleWSSClientDeployment32.wixobj

To test the Windows Installer package, you can run it by double clicking the .msi file, verify that the files were copied to the appropriate places, and then you can remove the package. The package can be removed by uninstalling it from the Control Panel.

To create an .msi file for a 64-bit client computer, see How to: Create the Windows Installer Package for 64-bit Client Computers.

© 2015 Microsoft