Problem calling COM DLL from Excel 2016 RRS feed

  • Question

  • Hi, I have a COM DLL which I developed in Visual Studio. It works perfectly in Excel 2010 but when I do the identical call from Excel 2016 I get an error “Class not registered”. Both versions of Excel are installed on the same computer. I’m at a complete loss at why it will work in one version of Excel but not in the other. I tried reinstalling Office, registering (RegAsm) my dll but no luck.

    Any help would be greatly appreciated.
    Thursday, September 12, 2019 10:31 PM

All replies

  • Hi,

    I'd like to ask a stupid question.
    In Excel 2016, have you add the COM DLL in [Available References] in an Excel book?
         VB editor - [Tools] - [References]


    Ashidacchi --

    Friday, September 13, 2019 6:30 AM
  • Hi compassion365,

    Sorry for delay in reply.

    According to your description, we suggest you could register your dll using (Regsvr32.exe), the difference between Regsvr32 and RegAsm from this answer:


    regsvr32: will load the library and try to call the DllRegisterServer() from that library. It doesn't care what DllRegisterServer() actually does - it just calls that function and checks the returned value. You use it to register COM servers in unmanaged DLLs. It can't generate a .tlb file.

    regasm: will register a COM-exposed .NET assembly as a COM server. You use it for .NET assemblies. It can generate a .tlb file given the assembly only - it inspects the type infromation stored in the assembly and includes the COM-exposed entities into the type library.


    And if it persists, please refer this case :

    Any feedback will be expected.

    Best Regards,


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact

    Monday, September 16, 2019 3:50 AM