这个问题是关于直接从程序集获取版本的。我已按照 this post 的说明进行操作
我的脚本如下所示。
#define MyAppName "Keyboard Trader"
#define SrcApp "Keyboard Trader.exe"
#define FileVerStr GetFileVersion(SrcApp)
#define StripBuild(str VerStr) Copy(VerStr, 1, RPos(".", VerStr)-1)
#define AppVerStr StripBuild(FileVerStr)
但是在编译脚本时抛出以下错误
Compile started: Tuesday, Oct 11 2011 at 01:15 AM
---
Compiling script with Inno Setup 5.4.2 (a)
---
[ISPP] Preprocessing.
---------------------
Compile Error!
Line: 12
**Error: [ISPP] Actual parameter VerStr is not of the declared type.**
我在这里缺少什么?
最佳答案
GetFileVersion() 返回一个空字符串,因为它找不到 SrcApp 路径。 尝试指定完全限定路径或使用:
#define SrcApp AddBackslash(SourcePath) + "Keyboard Trader.exe"
关于installation - 自动构建 inno 设置错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7722088/