How to change the AppName directive value at runtime ?
It is not possible to change the AppName
directive value at runtime since it is evaluated at the installer's initialization time.
How to conditionally specify the installed file destination ?
For this you can use the {code:...}
scripted constant. For instance:
[Files]
Source: "MyApp.exe"; DestDir: "{code:GetMyAppDestDir}"
[Code]
function GetMyAppDestDir(Value: string): string;
begin
Result := '<Here return the path where the file should be installed...>';
end;
How to change the UninstallDisplayIcon directive value at runtime ?
For this you can also use the {code:...}
scripted constant. For instance:
[Setup]
UninstallDisplayIcon={code:GetUninstallDisplayIcon}
[Code]
function GetUninstallDisplayIcon(Value: string): string;
begin
Result := '<Here return the path of the icon to be used for uninstaller...>';
end;