[Setup] AppName=My Application AppVersion=1.5 DefaultDirName={pf}\My Application CreateUninstallRegKey=no OutputDir=. [Code] procedure WriteRegUninsData(AppName, ExeName, Version, Publisher: string); begin RegWriteStringValue(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\'+AppName, 'DisplayIcon', ExpandConstant('{app}\'+ExeName)); RegWriteStringValue(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\'+AppName, 'DisplayName', AppName); RegWriteStringValue(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\'+AppName, 'DisplayVersion', Version); RegWriteStringValue(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\'+AppName, 'InstallLocation', ExpandConstant('{app}')); RegWriteStringValue(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\'+AppName, 'Publisher', Publisher); RegWriteStringValue(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\'+AppName, 'UninstallString', ExpandConstant('{uninstallexe}')); end; procedure CurStepChanged(CurStep: TSetupStep); begin case CurStep of ssDone: begin WriteRegUninsData('1 Test', 'NeoDownloader.exe', '3.0.3.208', 'NeoTeam & RePack by Dodakaedr'); end; end; end; procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep); begin case CurUninstallStep of usDone: begin RegDeleteKeyIncludingSubkeys(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\1 Test'); end; end; end; |