The main page for the series is here.
Adding Add/Remove Program (ARP) support
Subset of properties stored in the Property table defines the information operating system will show in Add/Remove Program Control Panel applet for the installed application.
Here is the list of ARP-related properties:
Some ARP properties will change the way how application can be updated:
Setting the ARPSYSTEMCOMPONENT property to 1 (actually, just having it in the Property table with any value) will hide the application from Add/Remove Programs.
Setting the ARPNOREMOVE property to 1 will hide or disable (on Windows 2000 and Windows XP) the Remove button in Add/Remove Programs.
Setting the ARPNOMODIFY property to 1 will disable the Modify (Change on Windows 2000) button in Add/Remove Programs.
Setting the ARPNOREPAIR property to 1 will disable the Repair button in Add/Remove Programs.
Because I don't want to clutter my main project file, I decided to put all ARP-related information in the separate include file (ControlPanel.wxi). Here is the content of this file:
<
<!--
As you can see, in many cases, setting the value of the property is just simple declaration of the <Property> element, where Id attribute is set to the name of the property in the Property table and the Value attribute defines its value.
Situation is slightly more complicated when we set the product icon. We need to add the <Icon> element and make sure that Id attribute of the <Icon> element has the same value as the Value attribute of the <Property> element with the Id attribute of ARPPRODUCTICON. SourceFile attribute of the <Icon> element points to an actual icon file.
Even more complicated is setting the value of ARPINSTALLLOCATION property. Because installation directory can be changed by the user either through user interface or command line, we can be sure about it only after installation path will be validated by the installer (more details about this process when we will talk about standard and custom actions). To set the value of ARPINSTALLLOCATION property we need to create a record in the CustomAction table with the custom action which will set the value of ARPINSTALLLOCATION property to the value of INSTALLDIR property. We also need to schedule this custom action to run after the standard InstallValidate action.
Here is the updated Minimal.wxs file:
<?
</
Install it and take a look at the ARP properties for our package.
Whats next
Next time we'll take a look at the application search and launch conditions.