2

I have developed an Outlook plugin with the help of NetOffice. It's running fine on my development PC, but I'm struggling building a deployment setup. I googled a lot, but all the tutorials seem to target developers who have a professional version of Visual Studio installed. I'm a hobby developer running Visual Studio Community 2015. Hence my usage of NetOffice and I don't have VSTO tools available. This site was the most helpfull so far: WiX installer for VSTO projects

I installed WiX and used the example in this site as a template. But this piece of code doesn't work for me:

<Component Id="CMP_DllManifest">
  <File Id="FILE_DllManifest" Source="$(var.NoReplyAll.TargetPath).manifest" KeyPath="yes" />
</Component>
<Component Id="CMP_VstoManifest">
  <File Id="FILE_VstoManifest" Source="$(var.NoReplyAll.TargetDir)$(var.NoReplyAll.TargetName).vsto" KeyPath="yes" />
     <RegistryKey Root="HKLM" Key="Software\Microsoft\Office\Outlook\Addins\NoReply">
        <RegistryValue Name="Description" Value="NoReplyAll Add-In" Type="string" Action="write" />
        <RegistryValue Name="FriendlyName" Value="NoReplyAll" Type="string" Action="write" />
        <RegistryValue Name="LoadBehavior" Value="3" Type="integer" Action="write" />
        <RegistryValue Name="Manifest" Value="[#FILE_VstoManifest]|vstolocal" Type="string" Action="write" />
     </RegistryKey>
 </Component>

The reason is that the .manifest and .vsto files don't exist in the output folder of my build. I googled to find out how to generate them, but the answer is to go into the project properties' "Linker" tab and make necessary settings. Only in my Visual Studio version this tab doesn't exist. So right now I'm stuck again.

Is there a solution for a cheap hobby developer who uses free tools?

1 Answers1

1

When I developed an Excel plugin with NetOffice, I created an installer with WiX#. Hopefully you can modify it for your purposes: https://gitlab.com/jbjurstam/ExcelAnimationRecorder/tree/master/Installer

You need to create separate installers for 64 and 32 bit, otherwise regasm will not work correctly. Your dll on the other hand can be built using AnyCPU (however, if you want to Debug it for 64 bit Excel, you need to build for 64 bit and set the debug target to Excel.exe). The installer invokes regasm, which in turn invokes the register method in your dll (which NetOffice generates for you). This is accomplished using a CustomAction.

Jbjstam
  • 874
  • 6
  • 13