We need you!

Icon

The IzPack documentation needs work, and you are invited to edit it!

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

The RegistryInstallerListener and RegistryUninstallerListener provide Windows registry access during an installation or uninstallation.

Due to the lack of Unicode support, there is no support from the IzPack project of this feature for Windows 95, Windows 98 and Windows ME, but just for Windows NT and higher.

The listeners themselves are only able to write into the Windows registry at installation and delete the writing at uninstall time.

To add registry support to an installation some changes in the installation definition file (install.xml) are to be made. First the declaration of the listener themselves:

For cleanup purposes it is recommended to add the uninstaller listener to not leave :trash: entries in the registry after uninstalling a product.

Now we need to add the native registry support to install.xml, see also Windows Registry Access:

The DLL file should be placed in ${basedir}/bin/native/3rdparty. The stage both marks this dll not only to be put into the installation jar file but also to be put into the uninstaller jar file. This is automatically performed by the packager and installation.

With these two changes the registry support will be incorporated into your installation. Without any more actions an uninstall key will be crated in the registry at the installation. If you open the software manager of Windows, there will be an entry with the variables $APP_NAME $APP_VER, e.g.:

The variables will be defined from the entries <appname> and <appversion> in the <info> element of the installation definition file.

If you would like to have more informations in the uninstaller key or to create other keys or values in the registry, you should create a specification file. The file should be then refered to in install.xml as resource:

The id has to be RegistrySpec.xml.

See also CheckedHelloPanel for getting information on how to use those registry entries in an installer. 

  • No labels