How can I set relative path to ini file in ReadIni?
This works:
#define MyAppVersion ReadIni("C:\Users\Popov\Documents\Release\Install.ini", "Release", "VersionNumber")
But I want this:
#define MyAppVersion ReadIni("Install.ini", "Release", "VersionNumber")
Where Install.ini is in the inno script folder.
Use the SourcePath
predefined variable, like this:
SourcePath str. Points to the directory where the current script is located, or the My Documents directory if the script has not yet been saved.
#define MyAppVersion ReadIni(SourcePath + "\Install.ini", "Release", "VersionNumber")
[Setup]
AppName=My Program
AppVersion={#MyAppVersion}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With