By — adlerweb 2013/04/17 13:59
Tree:
âââ delsub.ins âââ pidgin-2.10.7-offline.exe âââ pidgin.png âââ setup.ins âââ uninstall.ins
[Actions] requiredWinstVersion >= "4.10.8.6" DefVar $ProductId$ DefVar $MinimumSpace$ DefVar $UninstallCommand$ Set $ProductId$ = "pidgin" Set $MinimumSpace$ = "100 MB" ; ---------------------------------------------------------------- ShowBitmap "%ScriptPath%\" + $ProductId$ + ".png" $ProductId$ if not(HasMinimumSpace ("%SystemDrive%", $MinimumSpace$)) LogError "Not enough space on %SystemDrive%, " + $MinimumSpace$ + " on drive %SystemDrive% needed for " + $ProductId$ isFatalError ; Stop process and set installation status to failed else if FileExists("%ScriptPath%\delsub.ins") comment "start uninstall" sub "%ScriptPath%\delsub.ins" endif comment "installing" comment "Start setup program" Winbatch_install endif [Winbatch_install] "%ScriptPath%\pidgin-2.10.7-offline.exe" /DS=1 /SMS=1 /L=1031 /S
[Actions] DefVar $ProductId$ DefVar $UninstallCommand$ Set $ProductId$ = "pidgin" ShowBitmap "%ScriptPath%\" + $ProductId$ + ".png" $ProductId$ if FileExists("%ScriptPath%\delsub.ins") comment "start uninstall" sub "%ScriptPath%\delsub.ins" endif
set $UninstallCommand$ = GetRegistryStringValue32 ("[HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Pidgin] UninstallString") if not ($UninstallCommand$ = "") Message "Found "+$ProductId$+" => uninstalling first" killtask "pidgin.exe" Winbatch_uninstall endif [Winbatch_uninstall] "$UninstallProgram$" /S