Skip to main content

Hi,

I have come across a situation where we RMB on a window (ex - Busuiness Activity window) and hit on ‘Create Outlook Meeting with Attachments..‘ an error throws as below.

"Retrieving the COM class factory for component with CLSID {0006F03A-0000-0000-C000-000000000046} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))".

Solution

There could be different solutions to this based on the root cause. 

One solution could be to Register the class if it has not registered by creating an instance of it with the Application.CreateItem() method. 


Your code will look something like this -> Globals.ThisAddIn.Application.CreateItem(Microsoft.Office.Interop.Outlook.OlItemType.olAppointmentItem

 

But, In my scenario the issue was with the build properties platform target. It has to be fixed when building the project by changing the Project build properties Platform target from 'Any CPU' to x86 or x64 based on customer's prevailing system.

So, I think in this type of an issue it's always good to have an idea about the target component version and the outlook application version as well. Hope it could minimise your time on investigations.

There could be other handy solutions depending with the scenarios you may have come across. Please feel free to add them as well . :)