PDA

View Full Version : Cant find the failure


aemik
28th June 2007, 08:03
Section "un.Uninstaller"
RMDir /r "$INSTDIR"
RMDir /r "$APPDATA\Company\Test Program"
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Test Program"
Delete "$DESKTOP\Test Program.lnk"
Delete "$SMPROGRAMS\Company\Test Program.lnk"
Delete "$SMPROGRAMS\Company\Uninstall Test Program.lnk"
RMDir "$SMPROGRAMS\Company"
SectionEnd



Hello,

Please help me. I cant find the mistake in my program. The Installation runs perfectly. But the Uninstallation only delets the $INSTDIR. All other commands will be ignored like Shortcuts or the $appdata folder.

Thanks
Aemik

Red Wine
28th June 2007, 08:17
There isn't such section "un.Uninstaller" that could be a function.

Try section 'Uninstall'

edit:
Also if you've added SetShellVarContext All for installer, you need to do the same for the uninstaller in order to remove directories like $APPDATA $DESKTOP etc.

aemik
28th June 2007, 08:56
Thank you. Ive found my mistake!

Afrow UK
28th June 2007, 10:32
aemik, you might want to look at this regarding your uninstall code:
http://nsis.sourceforge.net/Validating_%24INSTDIR_before_uninstall

Stu