Creating Windows Installer Packages

The last method of deploying registry settings I discuss in this chapter is creating Windows Installer package files. You've undoubtedly encountered package files by now. Microsoft Office 2000 and Office XP both ship as package files, which are databases of files and settings that Windows Installer installs on the computer. Creating a package file for a large application is an intense process, but creating package files that contain registry settings is straightforward.

To create a package file, you need an editor. One of the most popular package editors is VERITAS WinINSTALL, and you can learn more about this enterprise-class tool at www.veritas.com. If you don't want to fork over the cash necessary to purchase a full version of WinINSTALL, you can get a free version if you still have your Microsoft Windows 2000 Professional CD lying around. Look in the Valueadd\3rdparty\Mgmt\Winstle folder. This is an older limited edition version of WinINSTALL. It's clunky and short on features when compared to recent versions of WinINSTALL, but it's suitable for creating package files to deploy registry settings. Install the program by double-clicking Swiadmle.msi. This installs WinINSTALL on the Start menu: Click Start, All Programs, VERITAS Software, VERITAS Software Console to run it.

Package files contain features, and features contain components. To deploy registry settings in a package file, you must create all of the above. Follow these steps to create a new package file and add registry settings to it:

  1. In the left pane of Veritas Software Console, right-click Windows Installer Package Editor, and then click New. In the Filename box, type the path and name of the package file, and click OK.

  2. In the left pane, right-click the package file you created, and then click Add Feature. In the Name box in the right pane, type a new name for the feature.

    This is likely to be the only feature that you add to the package file, because all you're doing is deploying registry settings. You can create multiple features, though, and each feature can contain different registry settings. That way, users can install or not install individual features.

  3. In the left pane, right-click the feature you created in step 2, and then click Add Component.

    The package editor automatically gives the component a GUID. Components typically contain all the files and settings required to implement a program unit, so applications often have multiple components. When using a package file to deploy settings, creating multiple components doesn't make a lot of sense.

  4. In the left pane, select the component you added, and click Registry.

  5. In the right pane, right-click the root key that you want to edit, and click New Key. Continue creating subkeys by right-clicking a key and clicking New Key until you've created the full path of the key that you want to edit.

  6. In the right pane, click the key in which you want to add or change a value, and then click New Value. In the Value Name box, type the name of the value. In the Data Type list, select the value's type; click OK. In the Type Editor dialog box, type the value's data, and then click OK.

  7. Click File, Save to save your package file.

After you've created a package file, you can deploy it just like any other package file. For example, users can simply double-click the package file to install it. If the package file contains settings that users don't have permission to change, you can deploy it through Active Directory and Group Policy, which installs package files with elevated privileges. You can also execute the command that installs a package file, which is msiexec.exe" /i filename.msi.



Microsoft Windows XP Registry Guide
Microsoft Windows XP Registry Guide (Bpg-Other)
ISBN: 0735617880
EAN: 2147483647
Year: 2005
Pages: 185

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net