In my setup I try to generate application version by code, however I don't manage to call it. My setup looks like this:
#define ApplicationVersion GetVersion('Application.exe')
[Setup]
AppVersion={#ApplicationVersion}
VersionInfoVersion={#ApplicationVersion}
...
[Code]
function GetVersion(Param: String): String;
begin
{ some magic ... }
Result := '1.2.3';
end;
I also tried
[Setup]
AppVersion={code:GetVersion}
VersionInfoVersion={code:GetVersion}
Any idea to achieve the user-function call?
Note, #define ApplicationVersion GetFileVersion('Application.exe') does not work because "Application.exe" does not provide any version information.