Old 23rd April 2004, 08:27   #1
nbroers
Junior Member
 
Join Date: Apr 2004
Posts: 11
Uninstaller in different folder

Hi,

I need to put the uninst.exe file in a subdirectory of the INSTDIR. But when running the uninstaller, it fails to delete the files from INSTDIR.

Is INSTDIR set to the folder where uninst.exe is stored for the uninstaller? Why does this happen?
nbroers is offline   Reply With Quote
Old 23rd April 2004, 12:13   #2
evilO
Senior Member
 
Join Date: Jan 2004
Location: Strasbourg, Europe
Posts: 117
Hi

Yes, INSTDIR is set to the folder where the uninstaller is stored when running the uninstaller. What you can do is to redefine it in the 'pre' function of the uninstaller's confirm page:

; If you need to save the uninstaller's location
Var UNINSTDIR

!define MUI_PAGE_CUSTOMFUNCTION_PRE un.onPreConfirmPage
!insertmacro MUI_UNPAGE_CONFIRM



Function un.onPreConfirmPage
StrCpy $UNINSTDIR $INSTDIR

; Put some code here to retrieve the real INSTDIR
; (from the registry or from an 'ini' file for instance)

FunctionEnd


Let me know if it doesn't work..

evilO/Olive
evilO is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump