1

how can i set via ISTool these things:

  • How can i set instalation path based on 64/32 system? I would like to see, that setup will use right instalation path if user have 32/64 system.

  • I want, that setup will create specific registry key where will be instalation path based on user instalation folder. User can change folder but I do not how to create dynamic registry key. I can create fix registry key that will write what I want.

Example: HKEY_CURRENT_USER\Software\Ascaron Entertainment\Sacred 2]
"ShortcutProgramMenu"="Installed"
"Language"="en_UK"
"Speech"="en_UK"
"MovieTrack"="5"
"CurrentVersion"="2.34.0.0"
"InstallPath"="{PATH}\\"
"LastUpdateCheck"=dword:000b3872

[HKEY_LOCAL_MACHINE\SOFTWARE\Ascaron Entertainment\Sacred 2]
"Language"="en_UK"
"Speech"="en_UK"
"MovieTrack"="5"
"InstallPath"="{PATH}\\"
"CurrentVersion"="2.34.0.0"

I want that, InstallPath that will be based od user decision. Thx for help.

TLama
  • 75,147
  • 17
  • 214
  • 392
  • I'd recoment to use Inno Script Studio - it's somehow more polished and in your case it allows to import REG and INI files. – RobeN May 28 '13 at 14:35
  • ISTool can import REG/ INI files and i can do that. But question was to set path based od user choice. RobeN have answered this question :) Than you for tip. – Pepa Čumpelík May 28 '13 at 16:10

1 Answers1

2

Your [Registry] section would look like this:

[Registry]
Root: HKCU; Subkey: Software\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "ShortcutProgramMenu"; ValueData: "Installed";
Root: HKCU; Subkey: Software\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "Language"; ValueData: "en_UK";
Root: HKCU; Subkey: Software\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "Speech"; ValueData: "en_UK";
Root: HKCU; Subkey: Software\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "MovieTrack"; ValueData: "5";
Root: HKCU; Subkey: Software\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "CurrentVersion"; ValueData: "2.34.0.0";
Root: HKCU; Subkey: Software\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "InstallPath"; ValueData: "{app}\";
Root: HKCU; Subkey: Software\Ascaron Entertainment\Sacred 2; 
ValueType: dword; ValueName: "LastUpdateCheck"; ValueData: "$000b3872";
Root: HKLM; Subkey: SOFTWARE\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "Language"; ValueData: "en_UK";
Root: HKLM; Subkey: SOFTWARE\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "Speech"; ValueData: "en_UK";
Root: HKLM; Subkey: SOFTWARE\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "MovieTrack"; ValueData: "5";
Root: HKLM; Subkey: SOFTWARE\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "InstallPath"; ValueData: "{app}\";
Root: HKLM; Subkey: SOFTWARE\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "CurrentVersion"; ValueData: "2.34.0.0";

In this case if you will install application on 64bit system, you will find your HKLM keys in Wow6432Node. But if you want/need keys to be added to 64bit branch, you could create additional entries with Check: IsWin64.

Example:

Root: HKLM; Subkey: SOFTWARE\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "CurrentVersion"; ValueData: "2.34.0.0"; Check: not IsWin64
Root: HKLM64; Subkey: SOFTWARE\Ascaron Entertainment\Sacred 2; 
ValueType: string; ValueName: "CurrentVersion"; ValueData: "2.34.0.0"; Check: IsWin64
RobeN
  • 5,346
  • 1
  • 33
  • 50
  • 1
    So, {app} is magic word :) Thank you. But i not understand 64/32 bit versin. I have this game on 64 bit system but i can not see HKLM64 in registry. I have it like my example. So {app} will fix problem with differet path. But i do not if you understand, i want run instalation and game will show patch: Program files.... or Program Files (X86). – Pepa Čumpelík May 28 '13 at 16:08
  • It depends on Regedit.exe you run. Please see [this Micosoft's article](http://support.microsoft.com/kb/305097) – RobeN May 28 '13 at 16:31
  • OK. Thank you for help. This game is without registry in Wow6432Node,so it should be ok. – Pepa Čumpelík May 28 '13 at 17:37