Odd COM error when upgrading to 3.5

    General discussion

  • I'm in the process of investigating upgrading our various .net 1.1 apps to 3.5 and I have upgraded a com wrapper class that we have, however when I compile I get the error:


    error MSB3304: Could not determine the dependencies of the COM reference "eSIPPCore". Error loading type library/DLL. (Exception from HRESULT: 0x80029C4A (TYPE_E_CANTLOADLIBRARY))


    I have tried referencing this library into a couple of blank projects and get the same error, this particular dll works just fine using .net 1.1, and runs fine in our production environment, but simply wont compile is VS2008.


    Does anyone have ideas?



    Tuesday, January 29, 2008 11:18 AM

All replies

  • To troubleshoot this issue, we really need the source code and the detailed repro steps to reproduce the problem, so that we can investigate the issue in house. It is not necessary that you send out the complete source of your project. We just need a simplest sample to reproduce the problem. You can remove any confidential information or business logic from it.

    You can send a sample project and repro steps in details to may email address which can be found in my personal profile page.
    Wednesday, January 30, 2008 6:26 AM
  • We are changing the issue type to “Comment” because you have not followed up with the necessary information. If you have more time to look at the issue and provide more information, please feel free to change the issue type back to “Question” by editing your initial post and changing the radio button at the top of the post editor window. If the issue is resolved, we will appreciate it if you can share the solution so that the answer can be found and used by other community members having similar questions.

    Thank you!
    Sunday, February 03, 2008 4:00 PM
  • I can reproduce even though I'm using an older version of office (Office XP):


    Steps To Reproduce:

    1. Open Visual C# Express 2008

    2. Add a COM reference to "Microsoft Excel 10 Object Library"

    3. Paste the code below and attempt to build.

    4. Note that although the build completed, the error message has occured.



    using System;

    using Excel = Microsoft.Office.Interop.Excel;

    namespace ConsoleApplication1


    class Program


    static void Main(string[] args)


    Excel.ApplicationClass excelApp = new Excel.ApplicationClass();

    Excel.Workbook excelBook = (Excel.Workbook)(excelApp.Workbooks.Add(Excel.XlWBATemplate.xlWBATWorksheet));

    Excel.Sheets excelSheets = excelBook.Worksheets;

    Excel.Worksheet excelSheet = (Excel.Worksheet)excelSheets.get_Item(1);





    Error message:

    Error 1 Could not determine the dependencies of the COM reference "Excel". Error loading type library/DLL. (Exception from HRESULT: 0x80029C4A (TYPE_E_CANTLOADLIBRARY)) ConsoleApplication1

    This used to work for me under Visual C# Express 2005, so I don't know what the problem is (you can check it under that IDE if you have it).


    Please advise and thank you!

    Tuesday, February 05, 2008 8:48 PM
  • I am running Office 2003 on Vista Business, I have VS 2008 installed, and am having the same issue.  Here's my program:

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;

    using Excel = Microsoft.Office.Interop.Excel;

    namespace ConsoleApplication2
        class Program
            static void Main(string[] args)
                Excel.Application m_oExcelApp;
                Excel.Workbooks m_oBooks;
                Excel.Workbook m_oBook;

                Excel.Worksheet m_oSheet;

                Excel.Range excelRange;

                m_oExcelApp = new Excel.Application();

                m_oExcelApp.Visible = false;

                m_oBooks = m_oExcelApp.Workbooks;

                m_oSheet = null;

                m_oBooks = null;

                excelRange = null;


    And the errors I get:
    Error 4 Could not determine the dependencies of the COM reference "Excel". Error loading type library/DLL. (Exception from HRESULT: 0x80029C4A (TYPE_E_CANTLOADLIBRARY)) ConsoleApplication2
    Error 5 Could not determine the dependencies of the COM reference "VBIDE". Error loading type library/DLL. (Exception from HRESULT: 0x80029C4A (TYPE_E_CANTLOADLIBRARY)) ConsoleApplication2

    I have added the COM reference to "Microsfot Excel 11 Object Library", and the VBIDE library automatically added when I added the Excel library.

    Any ideas?

    Thursday, August 07, 2008 4:25 PM
  • I'm having a similar problem. When I try to reference a COM .dll named MECMOD I get the following:

    C:\WINDOWS\Microsoft.NET\Framework\v3.5\Microsoft.Common.targets(1396,9): error MSB3304: Could not determine the dependencies of the COM reference "MECMOD". Element not found. (Exception from HRESULT: 0x8002802B (TYPE_E_ELEMENTNOTFOUND))

    I get this error with a brand new project with just the reference.

    The really odd thing is that my projects with this reference were working fine a few days ago.

    I appreciate any help.

    • Edited by Carbaholic Tuesday, September 09, 2008 8:29 PM additional information added
    Tuesday, September 09, 2008 8:26 PM
  • If all of these problems work in some environments and not in others, it sounds like you're running into a versioning issue of some sort or another:

    • Consider using SysInternal's Process Monitor to watch the difference between a running and a broken system and look for different versions.
    • Are you running into the CLR v1 vs CLR v2 problem?  The first CLR to 'initialize' a process wins and the other CLR can't be started up within that process.  This means that if a component causes CLR v1.1 to be initialized in a process then subsequent uses ofa CLR v2 component (which would include .NET 3.5) would fail.  This is even more fun if you are using a non-deterministic way of initializing the CLR (for example: a global C++ object causing a CoInitialize() -- C++ globals do not run in a guaranteed order and the project would work sometimes and fail other times).

    The Fusion Log Viewer might be useful (FUSLOGVW) in finding these issues, but I'm not optimistic about it.

    If this is a larger system that you've 'inherited' or if you've had extensive 3d party components and/or assistance, you might need to take a closer look at how and when components are loaded.  You can use the WinDBG script at to generate a trace of which DLLs are loaded when.  By replacing one of the 'g;' in that script with 'kv; g;' you can get a sense of _who_ is doing the load and why.

    There is a step-by-step write-up of this at

    Good luck!

    Wednesday, September 10, 2008 6:03 PM
  • I have a similar problem!
    and the fact is that with VS2005 i have no problem referencing the interop.

    is this a known issue with VS2008? (or maybe with .net 3.5)

    Tuesday, September 16, 2008 10:40 AM
  • I'm having a similar problem.  I added a reference to Word 10.0 Object library, and now I get the "Coudl not determine the dependencies of the COM reference "VBIDE" ... And that VBIDE was loaded when I added the reference to Word 10.0.  This was working fine under VS 2005.  Any ideas?  Please help!
    Monday, December 15, 2008 11:08 PM
  • I know it's a while since this thread was created but I've come across this problem for the first time this week after uninstalling office 2007 from my computer.  Like your Excel reference I had a reference to MS Word 2003 (version 11).  This works fine when the project is compiled using VS 2005 but when using VS 2008 I get the error "Could not determine the dependencies of the COM reference "Word".
    Luckily, I have a laptop which was set up exactly the same as my development machine before the uninstall of Office 2007 so I was able to compare the difference between them and found that the 'Office12' folder located at C:\Program Files\Common Files\Microsoft Shared\ was missing.  Reinstating this folder on my development computer led to the warning/error disappearing.
    So there must be a dll or some other file in that folder that VS 2008 needs in order to determine the com references but I haven't been able to establish which one.
    Hope this info helps others in the same predicament.
    Monday, May 11, 2009 4:32 PM
  • Got the same problem while upgrading a perfectly good project to Visual Studio 2008. The build also "succeeds" even if the error is output. The faulty reference is NOT an office reference though, it's a reference to VCPlatformX360V90.dll, installed from an XDK.
    Tuesday, February 23, 2010 3:11 PM
  • The domain appears to have died. It would be nice to know how to do this work!
    Friday, July 13, 2012 5:23 PM