Installation Inno安装程序-如果未安装其他程序,则跳过安装

Installation Inno安装程序-如果未安装其他程序,则跳过安装,installation,inno-setup,skip,Installation,Inno Setup,Skip,如果没有安装其他程序,我必须找到跳过安装的方法。我可以检测其他程序的注册表(基本脚本返回真/假),这不是问题。但我不知道如何跳过安装 简而言之:如果注册表中有一个键未设置,请在这个键之前打印消息“instal program xyz”,然后完成installator 这很容易。加上 [Code] function IsApp2Installed: boolean; begin result := RegKeyExists(HKEY_LOCAL_MACHINE, 'SOFTWARE\

如果没有安装其他程序,我必须找到跳过安装的方法。我可以检测其他程序的注册表(基本脚本返回真/假),这不是问题。但我不知道如何跳过安装


简而言之:如果注册表中有一个键未设置,请在这个键之前打印消息“instal program xyz”,然后完成installator

这很容易。加上

[Code]

function IsApp2Installed: boolean;
begin
  result := RegKeyExists(HKEY_LOCAL_MACHINE,
    'SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\app2.exe');
end;

function InitializeSetup: boolean;
begin
  result := IsApp2Installed;
  if not result then
    MsgBox('You need to install App2 before you install ThisApp. Install App2 and then run this installer again.', mbError, MB_OK);
end;
到你的ISS文件
InitializeSetup
是一种所谓的安装程序,在安装程序启动时执行(甚至在显示向导GUI之前)。如果返回
false
,安装程序将立即退出