0
votes

I have a registry value setter in my wix application as follows

<Component Id="EngageAssistanceAutostart" Guid="f9e92a81-506d-4fe9-836b-564420a98ea1" Win64="yes">
    <RegistryValue Id="crimsonwatchdog" Root="HKLM" Action="write"
           Key="Software\Microsoft\Windows\CurrentVersion\Run"
           Name="Crimson watch dog"
           Value="[INSTALLFOLDER]Crimson.Watchdog.exe"
           Type="string" />

as you can see, to edit registry in windows 64 bit system, I have kept win64="yes"

and I also have to set patform="x64"

  <Package InstallerVersion="200" Platform="x64" Compressed="yes" InstallScope="perMachine" InstallPrivileges="elevated" AdminImage="yes" />

if I didn't do this I wont be able to set reg. value in 64bit system. if I do this, this installer wont work in 32bit system.

is there any solution which will allow me to set registry value in both 64 and 32 bit system?

1

1 Answers

1
votes

You don't need to set platform to x64 to create registry in 64bit hive. Component will decided where this registry will be created. In your case, because it's only RUN key, you should create single component that is not set to x64.

What MSI will do whit such component.

On x86 machine, registry key will be created in standard location. On x64 machine, registry key will be created under Wow6432Node but for Run this should be not a problem.