Archive: How to uninstall components?


How to uninstall components?
Hello guys,
on the internet I found this gread installer NSIS. Though it is a bit complex, so I used HM Nis Edit.

But I cannot find a good script for removing / uninstalling my components! With my Installation I can install 5 components and one is always required (cannot be turnt "off"). But after installting and trying to uninstall it, I'm not able to deselect my installed components, just the hole installed pack.

So do you guys know an Editor or a Wizard which features this option to create an uninstaller of the components.

I am thankful for any answers, recommendations or tips.


Add MUI_UNPAGE_COMPONENTS as explained in documentation, and organize your sections in the same way they are organized in your installer and you're done.
Remember that uninstall sections/functions need the UN. prefix.


Thx! That helped!

Now I have two other questions:
1. How can I delete a shortcut folder in my start menu (I used RMDIR und RMDIR /r, but NSIS deleted my entire start menu!)?
I tried to delete all shortcuts in it, but the shortcuts won't be uninstalled and the folder remains in the menu.
2. In the uninstaller I want to create an dependancy of sections. If I select the first section, the other three should be selected / included too (maby shaded with gray so that you cannot untick them). How can I manage this? Do I have to use the command onSelChange?


1. Check the path and try again. "$SMPROGRAMS\My Folder"

2. Yes, you have to handle this in .onSelChange using the macros provided in Sections.nsh.

Stu


I have a little problem:
The .onSelChange should only be used in the uninstaller and not in the installer, because I want to make a section in the uninstaller called "delete all" with which you just tick all the other sections.

But the problem is: I cannot include the function onselchange into the section of my "delete all" component, because you cannot put a function into that section!

How can I manage it to get onselchange into the uninstaller?