Troubleshoot Outlook 2003 Add-in written in VSTO SE Deployment

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Hello Office Developers,

I need your advice on how best to troubleshoot an add-in after it gets
installed on a "client" machine. I assume it's a deployment issue, because
the add-in works on a development machine.

This add-in was created using Visual Studio 2005 C#, using the VSTO SE
Outlook 2003 template. (VSTO SE because the template creates the
"ThisAddIn" partial class.) My add-in has one line - messagebox.show(
"Hello World" ). I followed the two-part article that described "how to
deploy VS 2005 tools for office solutions using windows
installer"(http://msdn2.microsoft.com/en-us/library/aa537173(office.11).aspx).
I added the prerequisites, created an installer class that set full trust.

On the development machine, the app installs and shows "Hello World" on
startup.
On a client machine, it does not work. Something is different.

Could it due to CAS/Full-Trust? Maybe. I see the trust granted in Net 2.0
framework configuration. Caspol -rsg myaddinname.dll also shows it as full
trust. (the MS walk-thru gave full trust to the application directory) Also,
If I create an Outlook 2003 add-in using the VSTO template (not VSTO SE),
and use the same "setSecurity.cs" installer project, the VSTO add-in
successfully installs and runs on the client machine.

What's different about the VSTO SE code? The VSTO SE add-in is not on the
client's Outlook's "Disabled Items" list. It could be a Net 1.x framework
problem, although the VSTO add-in works, and there are no other add-ins (I
know of) installed in that client's Outlook.

Per Misha Shneerson's VSTO BLOG suggestion I set an environment variable
VSTO_SUPPRESSDISPLAYALERTS variable to 0. When I re-open Outlook, it throws
an exception in a message box. Is it a compatibility issue with
"Microsoft.Office.Tools.Common"? I've attached the first part of the
Outlook Error message from the pop-up to the bottom of the

This one has me stumped. How do I debug this issue?

Thanks for slogging through this long post.
-Russ
Could not load type 'Microsoft.Office.Tools.AddIn' from assembly
'Microsoft.Office.Tools.Common, Version=8.0.0.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a'.


************** Exception Text **************
System.TypeLoadException: Could not load type 'Microsoft.Office.Tools.AddIn'
from assembly 'Microsoft.Office.Tools.Common, Version=8.0.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
at System.Reflection.Assembly.GetType(String name, Boolean throwOnError,
Boolean ignoreCase)
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.CreateStartupObject(EntryPoint
entryPoint, Dependency dependency, Assembly objectAssembly)
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.ConfigureAppDomain()
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.LoadAssembliesAndConfigureAppDomain(IHostServiceProvider
serviceProvider)
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.ExecuteCustomization(IHostServiceProvider
serviceProvider)


************** Loaded Assemblies **************
mscorlib
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.42 (RTM.050727-4200)
CodeBase:
file:///C:/WINDOWS/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
Microsoft.VisualStudio.Tools.Applications.Runtime
Assembly Version: 8.0.0.0
Win32 Version: 8.0.50727.42
CodeBase:
file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.VisualStudio.Tools.Applications.Runtime/8.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Tools.Applications.Runtime.dll
----------------------------------------
Microsoft.Office.Tools.Common
Assembly Version: 8.0.0.0
Win32 Version: 8.0.50727.42
CodeBase:
file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.Office.Tools.Common/8.0.0.0__b03f5f7f11d50a3a/Microsoft.Office.Tools.Common.dll
----------------------------------------
System
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.42 (RTM.050727-4200)
CodeBase:
file:///C:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Windows.Forms
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.42 (RTM.050727-4200)
CodeBase:
file:///C:/WINDOWS/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
TESTOUTLOOKClient
Assembly Version: 1.1.0.0
Win32 Version: 1.1.0.0
CodeBase: file:///C:/RVI/TEST/testoutlookclient.DLL
----------------------------------------




.



Relevant Pages

  • Re: Is vsto what I want to use?
    ... Use a VSTO template-level customization. ... Use a managed COM add-in. ... template solution and put all your common library code, ... > library of functionality for Word that's all written in VBA. ...
    (microsoft.public.vsnet.vstools.office)
  • Re: Deploying VSTO 2005SE COM Add-Ins
    ... Unfortunately the setup project automatically created by VSTO 2005 SE ... help if you're having problems trying to deploy a Visio VSTO 2005SE COM ... After running the setup program generated for a VSTO COM Add-in, ...
    (microsoft.public.visio.developer)
  • RE: Mysterious issue with shared COM add-in deployment...
    ... I had this problem when trying to deploy to machines having older versions ... Has anybody made an Excel Add-in in VS 2005 that can actually be ... This is not handled automatically by the installer. ... the setup project ought to have this covered. ...
    (microsoft.public.office.developer.com.add_ins)
  • Re: VSTO add-in and Outlook 2003
    ... Look at the information about deploying VSTO addins on the VSTO page at www.outlookcode.com, ... The add-in does not run in outlook. ...
    (microsoft.public.office.developer.com.add_ins)
  • Re: Add-in Express for .NET 2007 - is it worth it?
    ... You could get VSTO 2005 SE for free, but for that you need VS 2005, and I don't think the Express editions do it. ... Maybe Add-in Express is not the worst solution for you...What do you think Dennis? ... - A toolbar button and context menu item in Outlook that Querys our SQL ... executed by a VBA macro. ...
    (microsoft.public.office.developer.com.add_ins)