correct old uninstaller handling

This commit is contained in:
Mario Fetka 2013-03-12 07:18:38 +01:00
parent 5b50aa63b1
commit 87a2079324
3 changed files with 6 additions and 2 deletions

View File

@ -4,7 +4,6 @@
; credits: http://www.opsi.org/en/credits/
Set $UninstallProgramOld$ = $InstallDir$ + "\" + $UninstallProg$
Set $UninstallProgram$ = $InstallDir$ + "\unins000.exe"
Set $IniFile$ = $InstallDir$ + "\opsi-" + $ProductId$ + ".ini"
@ -16,7 +15,8 @@ endif
Message "Uninstalling " + $ProductId$ + " " + $OLD_VERSION$ + "-" + $OLD_CREATOR_TAG$ + $OLD_RELEASE$ + " ..."
if FileExists($IniFile$)
Set $UninstallProgramOld$ = GetValueFromInifile($IniFile$,"X86","UninstallProg","XXXXXXXX.exe")
Set $UninstallProg$ = GetValueFromInifile($IniFile$,"X86","UninstallProg","XXXXXXXX.exe")
Set $UninstallProgramOld$ = $InstallDir$ + "\" + $UninstallProg$
if FileExists($UninstallProgramOld$)
comment "Uninstall program found, starting uninstall"
Winbatch_uninstall_old
@ -40,6 +40,7 @@ LinkFolder_uninstall
[Winbatch_uninstall_old]
"$UninstallProgramOld$" /SILENT /NORESTART /SUPPRESSMSGBOXES
sleepSeconds 5
taskkill /F /IM iexplore.exe
taskkill /F /IM iron.exe
taskkill /F /IM firefox.exe
@ -49,6 +50,7 @@ taskkill /F /IM opera.exe
[Winbatch_uninstall]
"$UninstallProgram$" /SILENT /NORESTART /SUPPRESSMSGBOXES
sleepSeconds 5
taskkill /F /IM iexplore.exe
taskkill /F /IM iron.exe
taskkill /F /IM firefox.exe

View File

@ -6,6 +6,7 @@
[Actions]
requiredWinstVersion >= "4.11.2.6"
DefVar $UninstallProg$
DefVar $UninstallProgram$
DefVar $UninstallProgramOld$
DefVar $IniFile$

View File

@ -6,6 +6,7 @@
[Actions]
requiredWinstVersion >= "4.11.2.6"
DefVar $UninstallProg$
DefVar $UninstallProgram$
DefVar $UninstallProgramOld$
DefVar $IniFile$