VSTO Troubleshooting Quick Tips

If you ever find yourself troubleshooting a VSTO addin that does not load then these steps will interest you.

  1. Do not skip the basics and check the registry at HKLM\Software\Microsoft\Office\<Application>\AddIns\<AddInName> or HKCU\Software\Microsoft\Office\<Product>\AddIns\<Application> because if the LoadBehavior key is not set to 3 the office application will not even try to load it on startup;
  2. Enable error alerts popups by configuring an environment variable
    SET VSTO_SUPPRESSDISPLAYALERTS=0
  3. Enable logging errors to file by configuring an environment variable
    SET VSTO_LOGALERTS=1
  4. Pray for an error alert popup or for an error in the log file so that you can fix its cause.

 

About these ads
Leave a comment

2 Comments

  1. Yeah, well, sometimes none of this logging helps any, the VSTO file just isn’t loaded, period. No info to debug from.

    Reply
    • João Angelo

       /  September 17, 2012

      Indeed, I know what you mean, VSTO debugging can be painful, that’s why I start step 4 with a bit of praying to the VSTO gods, but sometimes they just don’t listen. I’ve been lucky and haven’t had the need to work with VSTO in the last year so I don’t have any more tips.

      Reply

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

Join 27 other followers