VB6 Add-in fails to load in Outlook 16 - message useless

Not open for further replies.

Jef Lee

New Member
Outlook version
Outlook 2016 32 bit
Email Account
Office 365 Exchange
I have an add-in created in VB6. I recently updated to Office 365 and Outlook 16 (10.0.6741.2071). I run Windows 7. Now my add-in has stopped loading. The message is:
"Not loaded. A runtime error occurred during the loading of the COM Add-in."
But, a little more information...
There is a development version of the add-in and a production version. Yesterday as I was starting this request, I went to get the error message to ensure it was word-for-word. Imagine my joy, confusion & annoyance when the add-in loaded and ran. Even in the VB6 IDE mode so I could debug it. There before my eyes was the development version running. I quickly told everyone that the issue had resolved itself - bad mistake!
Today I switched to the production version so I could run against a production database. This involves: unregistering the development version, checking the registry to ensure that was effective, then registering the production version. All that seemed to work perfectly. The add-in connection class pointed to the correct DLL. But, Outlook loaded the development version. The description was the production version's but the path was to the development version. I checked the registry for the add-in. All entries that I could read (ie not binary) were to the production version. I even tried deleting binary ones, just to be sure. Didn't help.
I tried hiding the development version - Outlook didn't like that.
Has anyone experienced this? I realise that this is a legacy add-in, but it's still a viable item (or is it?). If you know where Outlook is getting its add-in path from that would be appreciated.
Jef Lee, Perth, Western Australia.

Michael Bauer

Senior Member
Outlook version
Outlook 2010 32 bit
Email Account
Exchange Server
If a DLL is really not registered, then Outlook cannot load it. So I'd start looking there. If you use the project compatibility mode, there can be lots of entries in the registry. Maybe your way to unregister left some entries there.

Just curious, why do you have two different versions, why don't you debug and fix not just one version?

Jef Lee

New Member
Outlook version
Outlook 2016 32 bit
Email Account
Office 365 Exchange
Thanks for the comments Michael.

I'll check the registry for both the unwanted and the wanted to make sure only the latter is there.
There are two versions because the development is the next generation. While it may not have the difference scale as say Windows 7 to Windows 8, it is sufficiently different that it cannot be unleashed on the unsuspecting user - not yet anyway.

You comment "really not registered" suggests something is missing in the registry. I have the CLSID entry, the TypeLib entry, the program.connection class and the entry in the outlook add-ins list that points to those. I am not sure what would be missing. The LoadBehavior is set to 3 before I start Outlook and quickly changes to 2 when Outlook starts - I guess that's Outlook's reaction to a "bad" add-in.

I just changed the project compatibility to None and tested again - no change.

Have you had that error message? Or do you know where I can learn more about it? This error: "Not loaded. A runtime error occurred during the loading of the COM Add-in."


Michael Bauer

Senior Member
Outlook version
Outlook 2010 32 bit
Email Account
Exchange Server
Not sure what we are talking about, is the wrong version loaded, or doesn't load it at all? If the wrong version is loaded, then it has anything to do with the registry. If an Addin is not loaded at all, as the error message suggestes, then look at the startup code. If you don't have a working logging of errors, and if nothing else helps, then temporarily remove parts of the code until it works.

A compatibility mode of none means that with every compilation new GUIDs for the public classes will be created. If you don't unregister the dll beforehand, or if you don't change the class IDs, you'll end up with versions that cannot be removed by the uninstaller anymore.

Jef Lee

New Member
Outlook version
Outlook 2016 32 bit
Email Account
Office 365 Exchange
Sorry for the big pause. I was reassigned to something more pressing. Back now.
I got what you said about the project compatibility. I don't think that's an issue.
The start-up code hasn't changed. Until recently (two-three months), I could un-register the version I was working on and register the other version. Then I would start VB6, start Outlook and interact through the IDE as I put the Add-In through its paces in Outlook.
Then it broke.
There had been no changes to the connection mechanism in the DSR component. There had been changes to the business logic where the email item was handled.
So what could have changed?
My machine is the same, been so for over a year.
Still running Windows 7.
Upgraded Office to Office 365 ProPlus.
There have been regular MS Windows/Office/etc updates that are applied when I shutdown to go home.
I do not understand how it is that Outlook displays the wrong path to the Add-In. I have manually deleted ALL mention of the version I am not working on and registered the version that I am. I have used Agent Ransack to scurry through files to see if it can find the wrong path secreted in a file somewhere. The only registry entries I would not have deleted would be binary ones where I cannot "read" what the binary means. These do not get found as I search the registry anyway.
On Monday, if I get time, I will try the program called "Process Monitor" to see if I can identify what registry entries are being access by Outlook.
Very frustrating.
Have a great weekend. Supposed to rain Saturday here but fine again Sunday afternoon.
Not open for further replies.
Thread starter Similar threads Forum Replies Date
A vb6 run time error 5 when Outlook 2007 Explorer object displayed Outlook VBA and Custom Forms 1
R Sending email using VB6 Outlook VBA and Custom Forms 1
Y Encode TNEF file with VB6 Outlook VBA and Custom Forms 1
W OL2003 & VB6:- "Could not send the message" Outlook VBA and Custom Forms 7
Q VB6 to VB.Net Migration Outlook VBA and Custom Forms 3
G How to add a folder shortcut to outlook quick access toolbar? Using Outlook 5
G Add to Outlook Contacts - Point to non-default contacts folder Using Outlook 0
M Automatically add senders first name to a greeting Outlook VBA and Custom Forms 1
C Add Form to Appointments Received, Automatically Outlook VBA and Custom Forms 6
O Outlook tasks - Add text column with multiple lines Using Outlook 3
W April 2020 Office 365 Update - Add-Ons fail after Office 365 Update Using Outlook 6
B Task Filter Not Working When I add too many criteria Using Outlook 0
D Add date next to day name in Outlook Today calendar view Using Outlook 1
D iCloud Add-in not working in Outlook 2013 and Outlook 2016 After Windows Upgrade & iCloud Upgrade Using Outlook 2
P Add Paste Unformatted to QAT Using Outlook 1
M Ignore slow add-ins Using Outlook 0
B Add Prefix text to Subject Line Using Outlook 1
Jennifer Murphy Add birthdays to calendar Using Outlook 7
Z Add text to auto-forwarded e-mail Outlook VBA and Custom Forms 4
P Add, remove, & reorder folder pane Using Outlook 6
L Tired of Outlook disabling Adobe PDF Creator add-in Using Outlook 1
R Add 'Company' to Select Names Form Using Outlook 1
A Outlook 2016 Web add-in missing on some machines Using Outlook 9
P Syncing problems with add-ins Using Outlook 3
Mark Foley Cannot enable add-in in outlook 2010 Using Outlook 0
BretAB Is it possible to add a lookup field to a Message form? Outlook VBA and Custom Forms 4
J Add an Attachment Using an Array and Match first 17 Letters to Matching Template .oft to Send eMail Outlook VBA and Custom Forms 2
iwshim outlook 2013 - I cannot see the "Manage Add-ins" Using Outlook 2
A Add multiple servers "on behalf of" email to "safe senders" list. Using Outlook 1
S Add Exchange Account as Secondary to Existing PST? Exchange Server Administration 1
C Macro to add multiple recipients to message Outlook VBA and Custom Forms 3
A Add to Outlook Contacts from email - default view Outlook VBA and Custom Forms 1
P Add a contact to the New Task in Outlook 2016 Using Outlook 2
e_a_g_l_e_p_i Is there a way to add something that is in the "Format Text" tab to the "basic Text" on the message tab Using Outlook 1
B When working on emails in a certain folder, when I hit reply or reply all, I would like it re always reply all and add an email address to send to Outlook VBA and Custom Forms 3
M Macro to add date/time stamp to subject Outlook VBA and Custom Forms 4
O Outlook on Android - add BCC Using Outlook 2
J Execute Add-In Button from VBA Outlook 2016 Outlook VBA and Custom Forms 1
S Example VBA Macro - To Conditionally Change the From Account and Add a BCC Address on Emails Outlook VBA and Custom Forms 11
B When I add more search strings to RULES, it is not processing them Using Outlook 3
D Add Tetxbox at form open Outlook VBA and Custom Forms 1
Andrew Quirl Open attachment, manipulate without add-on program? Outlook VBA and Custom Forms 5
B Searching for a Add-In Using Outlook 3
J Add Fillable Fields to Existing Template Outlook VBA and Custom Forms 1
J vb to c# for Outlook add-in. Using Outlook 0
S Send email via SMTP - use transport rules to add to senders inbox (then rule to move to sent items Exchange Server Administration 1
R Outlook add-in to create new contact from an email. Using Outlook 0
twofivepie GTD Netcentrics add-in for 2016 Outlook VBA and Custom Forms 13
D Add all meeting rooms to the meeting request by default Outlook VBA and Custom Forms 0
A add birthday to outlook contacts Using Outlook 1
Similar threads