On Monday, November 10, 2025, 18:49:43, Jan Bleiss wrote:
The installer runs without asking the user for the installation directory. However, I would like it to do so in case the registry does not contain what it should. Which command can I use to make the setup ask for the destination folder in any case, but with the entry found in the registry as the default value?
Make sure you're doing a clean install; by default if you ran Setup with the same AppId before, Inno will skip the directory page, and automatically use the previous installation path.
If IsWin64 then begin
RegQueryStringValue(HKEY_LOCAL_MACHINE, “SOFTWARE\WOW6432Node\railsimulator.com\RailWorks”,'Install_Path',Result);
end
Else begin
Result := “c:\program files(x86)\steam\steamApps\common\railworks”;
end;