Archive: Help with Uninstall Section


I have now Successfully completed my Sections thnx to cchian and Duane, but now have some problems with th Uninstall Section. If you read the last post then you'd know I was making a Install and Restore in one. The only Problem now is for the Install, I have an Uninstalled for the Registry Entries. For my Restore Section can I bypass the Uninstall String? because I don't need the uninstall part for the restore. If not I guess it's not that Bad I'll just trash the Uninstall and put the Uninstall String combined with the restore.
Thnx
-Rothgar


Wow, I never heard of an restore section. But the Uninstall is created AFTER the install. Which means you can have the uninstaller in there but DON'T execute it. If you are trying to create an installer for newer versions, just do something like this:

Name "Installer"
Outfile name.exe
Icon xxxxxx.ico

InstallDir "$PROGRAMFILES\my program"
InstallDirRegKey HKLM SOFTWARE\MP ""

Section ""
SectionIn 1 2 3 4 5 6
SetOutPath $INSTDIR
File myfile.exe
SectionEnd

Section -post
;Here is where you would delete the RegistryKey
;then update the regkey
SectionEnd

UninstallExeName uninst-myfile.exe
UninstallText "This will remove my file:"

Section Uninstall
;This is where you remove everything pertaining to you
;program.


Also keep in mind that NSIS always ReUpdates RegKeys. So when your new program is made, then all you may have to do is make sure to update your program as well as your regkeys.

Try that on for size,
Duane