views:

32

answers:

1

Hi!

I have developed an application level add-in for Outlook targeting Outlook 2010 and .NET 4 and I want to run it on Outlook 2007, which should not be a problem due to the new "no pia" feature of .NET 4 (see this blog post).

However, after deploying the add-in with my Windows Installer package (the same package works for Outlook 2010), the add-in does not get loaded correctly and its load behavior is set to 2.

The test machine has the following software installed (in the given order):

  • Microsoft Windows XP with Service Pack 2 (x86)
  • Microsoft Office 2007 Enterprise
  • Windows Installer 3.1
  • Microsoft Windows XP Service Pack 3 (x86)
  • Microsoft .NET Framework 4.0 (Extended)
  • Microsoft Visual Studio 2010 Tools for Office Runtime (x86)

The utility assemblies are included in my deployment location and the add-in is registered correctly (shows up in Outlook trust center and deployment manifest is also included). I do not reference any third party libraries.

The strange thing is that the CLR 4 is not even loaded into Outlook, which I can see through the Visual Studio 2010 Remote Debugger. When I create an test add-in on my development machine and throw an exception on add-in startup, the load behavior also gets set to 2 on startup (without debugging), but at least the CLR 4 gets loaded into the Outlook process. Has anyone ideas what (probably missing dependency) could cause the VSTO 2010 Runtime to not load .NET Framework 4? I have also tried reinstalling VSTO which caused no effect.

Best Regards,
Oliver Hanappi

A: 

I found the solution on the msdn forums. There is a problem when no clr 2 is installed. A hotfix is required in this case. For more details see http://social.msdn.microsoft.com/Forums/en/vsto/thread/d95cc828-fdb9-4622-bf09-291a25cea81b.

Oliver Hanappi