HOWTO: Creating a Project that Cannot be Uninstalled
Document ID: Q105100
This article applies to the following:
Product(s): InstallShield Professional 6.x
Last Revised On: 01/10/2001
Summary
How can I create an installation thatdo
es not appear in the add/remove programs applet in the Windows Control Panel, and cannot be removed?
--------------------------------------------------------------------------------
Discussion
By default, InstallShield creates an entry in the add/remove programs applet in the Windows Control Panel for each unique setup you install. If you desire to remove this entry, thereby not providing the user the option of uninstalling, you cando
so by removing the corresponding registry entry.
The uninstall key, which causes this entry in the add/remove programs applet in the Window Control Panel, is located in the following location in the registry:
HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/Windows/CurrentVersion/Uninstall/<your project GUID>
Simply delete this key using the RegDBDeleteKey function in the script portion of the project. It is recommended to call the function in the OnFirstUIAfter event, therefore occurring after all files have been transferred to the target machine.
The function call would look similar to the following:
szSubKey = "SOFTWARE//Microsoft//Windows//CurrentVersion//Uninstall" ^ PRODUCT_GUID;
RegDBDeleteKey (szSubKey);
Note: Your project GUID can be found by opening your project in InstallShield, clicking the Project pull-down menu, and selecting the Settings option.
--------------------------------------------------------------------------------
Additional Information
Removing the user抯 ability to uninstall the application should be seriously considered before following the steps outlined in this article.