1

I wrote a shell extension (item in explorer's file context menu), and used WiX's heat to create an MSI from the DLL.

PROBLEM: Installing the MSI does not make the context menu item appear.
In contrast, running Regasm.exe my.dll /codebase makes the item appear.

heat writes registry keys into HKEY_CLASSES_ROOT\, while
Regasm writes registry keys into HKEY_LOCAL_MACHINE\SOFTWARE\Classes\.

I could modify the heat-generated WXS to write to the same registry path as Regasm, but MSDN suggests HKEY_CLASSES_ROOT and apparently some users are not be able to write into HKEY_LOCAL_MACHINE... is there a better solution?

Community
  • 1
  • 1
Nicolas Raoul
  • 58,567
  • 58
  • 222
  • 373

1 Answers1

1

HKCR is an alias for HKLM\SOFTWARE\Classes\ when your MSI package is per-machine. The easiest way to ensure pre-machine package is to set the InstallScope on the Package element:

<Wix>
  <Product ...>
     <Package InstallScope='perMachine' />
Rob Mensching
  • 33,834
  • 5
  • 90
  • 130
  • Unfortunately the file context menu item still does not appear. – Nicolas Raoul May 23 '13 at 04:18
  • I've been searching for how to do this for ages, and have been using find-replace on my heat-generated fragments for months to guarantee that it is written into HKLM rather than HKCR. This is the perfect solution! –  Apr 04 '14 at 01:13