title: WIX 3 : Using HEAT for Visual Basic 6 COM Dlls
body: <p>I am using WIX 3. I have used heat to create a wxs file for a VB6 dll. The msi creates without any errors, and the installation is successful as well. </p>
  
  <p>All seems to be fine, and I can invoke the component successfully from a VB client.</p>
  
  <p>However, if I invoke the component from an ASP page, I get 0x800401f3.</p>
  
  <p>If instead of the installer, I use self registration (regsvr32), both work fine.</p>
  
  <p>I did a registry difference to figure out what was the difference between self registration (regsvr32) and the installer, and I see the following</p>
  
  <ol>
  <li>All entries in HKCR match - all well here</li>
  <li>regsvr32 adds entries in HKLM, while the installer does not touch HKLM</li>
  </ol>
  
  <p>I am wondering if this is the issue, or am I completely on a wrong track.</p>
  
  <p>MSDN (<a href="http://msdn.microsoft.com/en-us/library/ms694355(VS.85).aspx" rel="nofollow noreferrer">http://msdn.microsoft.com/en-us/library/ms694355(VS.85).aspx</a>) mentions that registry entries are required in HKLM, wondering what am I missing here.</p>
  
  <p>Following is the file created by heat.</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"&gt;
      &lt;Fragment&gt;
          &lt;DirectoryRef Id="TARGETDIR"&gt;
              &lt;Directory Id="dirAD70B10292EAB7CAC7171859FBB23AA9" Name="vbdll" /&gt;
          &lt;/DirectoryRef&gt;
      &lt;/Fragment&gt;
      &lt;Fragment&gt;
          &lt;DirectoryRef Id="dirAD70B10292EAB7CAC7171859FBB23AA9"&gt;
              &lt;Component Id="cmp9D818C62A6239E8B51E971A0048D0C05" Guid="PUT-GUID-HERE"&gt;
                  &lt;File Id="filDD6F51EC5018EF4A9A312FFA6AC4257D" KeyPath="yes" Source="SourceDir\vbdll\act.dll"&gt;
                      &lt;TypeLib Id="{80D8DA04-72C9-4D36-B269-57D989187ACF}" Description="act" HelpDirectory="dirAD70B10292EAB7CAC7171859FBB23AA9" Language="0" MajorVersion="1" MinorVersion="0"&gt;
                          &lt;Class Id="{31BD65B6-9479-40EB-83C0-E717CD4793DD}" Context="InprocServer32" Description="act.def" ThreadingModel="apartment" Version="1.0" Programmable="yes"&gt;
                              &lt;ProgId Id="act.def" Description="act.def" /&gt;
                          &lt;/Class&gt;
                          &lt;Interface Id="{C6D46026-CD7E-4AB0-B3B6-810FBF435BEF}" Name="def" ProxyStubClassId="{00020424-0000-0000-C000-000000000046}" ProxyStubClassId32="{00020424-0000-0000-C000-000000000046}" /&gt;
                      &lt;/TypeLib&gt;
                  &lt;/File&gt;
                  &lt;RegistryValue Root="HKCR" Key="CLSID\{31BD65B6-9479-40EB-83C0-E717CD4793DD}\Implemented Categories\{40FC6ED5-2438-11CF-A3DB-080036F12502}" Value="" Type="string" Action="write" /&gt;
              &lt;/Component&gt;
          &lt;/DirectoryRef&gt;
      &lt;/Fragment&gt;
  &lt;/Wix&gt;
  </code></pre>
  
  <hr>
  
  <p>Update : Using the "SelfReg" option for the File makes the ASP client work as well. I read from other posts that this is not to be used. Can someone tell me what's to be done?</p>