Re: How to see why Outlook Add-In not loading?

  • Thread starter Thread starter Randy Byrne [MVP - Outlook]
  • Start date Start date
R

Randy Byrne [MVP - Outlook]

Do you have a Try...Catch...End Try block in your OnConnection event? See
the sample OnConnection code in
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnout2k2/html/odc_oladdinvbnet.asp
You can also debug your Add-in by following these steps:

1. Select Properties on the Project menu.
2. Click Configuration Properties, then Debugging
3. Select Start external program option for Start Action, and point to
outlook.exe (usually under c:\program files\microsoft
office\office<majorversionnumber>\outlook.exe
4. Set breakpoints in OnConnection and elsewhere as required.
5. Press F5 to start the program.

--
Randy Byrne, MVP - Outlook
http://www.microeye.com
Building Applications with Microsoft Outlook 2002 (MSPress - July 2001)
Building Applications with Microsoft Outlook 2000 (MSPress)
http://www.microeye.com/books
Micro Eye ZipOut
http://www.microeye.com/zipout
 
Randy-

Thank you for replying. I started this add-in from your sample,
OutlookCOMAddinVBNET and bought "Building Applications With
Microsoft Outlook Version 2002". My first step was to get the known
good OutlookCOMAddinVBNET to load on my development machine by
doing such stuff as manually installing
Micorsoft.Office.Interop.Outlook.dll, etc. Then when i started my own
Extensibility2 project from scratch, it too worked in my development
environment.

It is on my target machine that does not have a development
environment that my add-in does not load. I had been hoping there was
a logging mechanism that Outlook might have to tell me the loading
error. I was afraid that if i did a complete install of Visual
Studio.NET
with sources and SDK, that there would be enough extra stuff in the
system that loading may work in the debug setup.

Before i hauled my CD's over to that machine, i think i have found the
reason the add-in is not being loaded just based on comparing the
working system to the non-working one. When we create the project,
the setup wizard program created at the same time has a dependency
check on the .NET framework being there. Inside the Solution Explorer
pane, the Detected Dependencies also list Office.dll and stdole.dll as
excluded dependencies. Both of those files live on my development
machine, but Office.dll is not in the Microsoft.NET folder and
stdole.dll is
not in the Global Assembly Cache on my target machine. I thought both
of these were supposed to be added at the same time our basic .NET
framework was added by running dotnetfx.exe. So now my question is
what is the right way to get these files added as part of the
installation?
Is dotnetfx the answer and it is not finishing it's complete
installation
because it's first check finds some files at Microsoft.NET\framework? Do
i want the setup wizard to get smarter by no longer excluding Office.dll
and stdole.dll in the list of dependencies? Should i link in something
like
dotnetfxredist... as part of the install? What's the best way to solve
this?

-Keithen
 
Back
Top