![]() |
A few registry questions
Hi,
I would like my end users to be able to install many instances of my application. For example they might want to have the same application at 3 different locations. 1: C:\application1\app.exe 2: C:\application2\app.exe 3: C:\application3\app.exe My problem is that application2 is writing over application1 in the registry and so forth. Also, the uninstaller is removing all sections from the registry, even if its not supposed to. What is the best way to increment entries in the registry? Or increment uninstall entries in the registry? How do I approach finding out which entry is the correct one to remove during the uninstallation? Thanks, |
you could keep a refrence count and only delete the entries if it is less than 1, or if they should not share settings, store with a hash of the path maybe (HKCU\Software\Company\Appname\%HASH%\)
|
Hello,
I have the same need as jrolling but don't know how to do it even with Anders' response. Installer name is the same (so registry markers are the same according to the wizard) but install directory is different and i have different installoptions parameters for each install. When the uninstaller is launched is it possible to have a page that lists installed components to uninstall (checkboxes)? |
You need to figure out a way to make the registry entries unique. One very simple thing to do is to have something
WriteRegStr HKLM "${REGKEY}\$INSTDIR\Components" Common 1 This way you know which entry to delete during uninstall and you can have. I would only recommend this for short time use until you come up with something better. You can make a custom uninstall page and during the un.init you can read your registry entry to find out which components are installed for that particular installation. Take a look at custom pages if you haven't already. |
I manage to have unique registry entries for installed components (ServiceName$nbpavi) and the number of installed components (InstalledPavi) by doing :
code: I also manage to add a components page to the uninstall : code: For exemple, when running the installer twice i can have : c:\Program Files\Pavi1 c:\Program Files\Pavi2 registry : "InstalledPavi" "2" "ServiceName1" "PAVI1" "ServiceName2" "PAVI2" My problem now is to know how to set "ServiceNameX" as uninstall sections in order to uninstall only selected services. If anyone as a clue. Thanks |
i changed some things :
i use code: instead of code: Then on un.onInit i use code: unsetup.ini contains a droplist that will be filled in function un.CustomPageB by looping values in the registry. code: i know i could use push and pop but i m not very comfortable with these... I have not finished yet but hope this is a good way to solve my need. |
| All times are GMT. The time now is 05:48. |
Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.