Have you taken a look at the documentation on registering preview handlers? http://msdn.microsoft.com/en-us/library/cc144144(VS.85).aspx explains pretty much everything in detail.
Here's some sample code for installing a 32-bit native code handler on both 32 and 64-bit systems, hope this helps. <Fragment> <Component Id="MyPreviewHandler.dll" Directory="APPLICATIONFOLDER" Guid="*"> <File Id="MyPreviewHandler.dll" KeyPath="yes" Source="SourceDir\MyPreviewHandler.dll" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\AcmeXYZ.Document\shellex\{8895b1c6-b41f-4c1c-a562-0d564250836f}" Value="{XXX-XXX-XXX-XXX}" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Microsoft\Windows\CurrentVersion\PreviewHandlers" Name="{XXX-XXX-XXX-XXX}" Value="XYZ Preview Handler" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}" Value="XYZ Preview Handler" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}" Name="DisplayName" Value="XYZ Preview Handler" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}" Name="DisableLowILProcessIsolation" Value="1" Type="integer" /> <!-- 32-bit handler needs to use different AppID on x64, refer http://msdn.microsoft.com/en-us/library/cc144144(VS.85).aspx --> <?if $(var.ProcessorArchitecture)=x64 ?> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}" Name="AppID" Value="{534A1E02-D58F-44f0-B58B-36CBED287C7C}" Type="string" /> <?else?> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}" Name="AppID" Value="{6d2b5079-2f0b-48dd-ab7f-97cec514d30b}" Type="string" /> <?endif?> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}\InprocServer32" Value="[!MyPreviewHandler.dll]" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}\InprocServer32" Name="ThreadingModel" Value="Apartment" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}\InprocServer32" Name="ProgID" Value="AcmeXYZ.Document" Type="string" /> <!-- Only install for Vista+ --> <Condition><![CDATA[VersionNT >= 600]]></Condition> </Component> </Fragment> <Fragment> <!-- 64-bit preview handler voodoo *waves hands magically* --> <Component Id="MyPreviewHandler_x64" Directory="XYZCommonFiles" Guid="*" Win64="yes"> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}" Value="XYZ Preview Handler" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}" Name="DisplayName" Value="!(loc.ApplicationName)" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}" Name="DisableLowILProcessIsolation" Value="1" Type="integer" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}\InprocServer32" Value="[!MyPreviewHandler.dll]" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}\InprocServer32" Name="ThreadingModel" Value="Apartment" Type="string" /> <RegistryValue Root="HKLM" Key="SOFTWARE\Classes\CLSID\{XXX-XXX-XXX-XXX}\InprocServer32" Name="ProgID" Value="AcmeXYZ.Document" Type="string" /> <!-- Only install for Vista+ --> <Condition><![CDATA[VersionNT >= 600]]></Condition> </Component> </Fragment> On Fri, Jul 16, 2010 at 2:23 AM, Daniel Moody <dani...@gibbscam.com> wrote: > Hello, > > I'm trying to register a Preview Pane handler for our product's files using > Wix. Unfortunately, Heat is unable to harvest anything from the preview > handler .dll file. Iit gives a HEAT5151 error and reports "Exception has > been thrown by the target of an invocation." I've tried using the > before-and-after registry snapshot approach, which has given me a large > number of registry keys and values, which oddly work fine on most computers > but not at all on a few. > > My installer is "GACing" the .dll just fine, and if I run regasm from a > command line after my installer is finished, everything works as expected. > > As I've just had the installer project transferred to me recently, I often > reference our old InstallShield installer to see what my predecessor did, > but in this case he used a binary custom action to manually run regasm, > something that I intend to avoid at all costs. > > Thanks, > > Daniel Moody | QA Engineer | Gibbs and Associates > > > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by Sprint > What will you do first with EVO, the first 4G phone? > Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > ------------------------------------------------------------------------------ This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users