Installation 选择C:\CustomFolder安装路径时,安装路径应为子文件夹C:\CustomFolder\Parent\Child

Installation 选择C:\CustomFolder安装路径时,安装路径应为子文件夹C:\CustomFolder\Parent\Child,installation,inno-setup,Installation,Inno Setup,当用户将安装文件夹更改为C:\CustomFolder时,基于Inno安装程序的安装程序应使用以下子文件夹进行安装:C:\CustomFolder\Parent\Child 到目前为止,我发现有一个选项,它将的最后一个组件附加到选定的文件夹名称。但这不是我需要的行为。一个简单的解决方案是在脚本中的任何地方使用{app}\Parent\Child,而不是简单的{app} 您可以为此创建一个示例,以避免重复 您可能还希望使用将卸载文件移动到这些子文件夹 #define TheAppPath "{

当用户将安装文件夹更改为
C:\CustomFolder
时,基于Inno安装程序的安装程序应使用以下子文件夹进行安装:
C:\CustomFolder\Parent\Child


到目前为止,我发现有一个选项,它将的最后一个组件附加到选定的文件夹名称。但这不是我需要的行为。

一个简单的解决方案是在脚本中的任何地方使用
{app}\Parent\Child
,而不是简单的
{app}

  • 您可以为此创建一个示例,以避免重复

  • 您可能还希望使用将卸载文件移动到这些子文件夹

#define TheAppPath "{app}\Parent\Child"

[Setup]
UninstallFilesDir={#TheAppPath}

[Files]
Source: "MyProg.exe"; DestDir: "{#TheAppPath}"
Source: "MyProg.dat"; DestDir: "{#TheAppPath}"