none
MS.Office.Interop issues when building RRS feed

  • Question

  • I recently ran into some issues related to updating that caused conflicts in my programs ability to open MS Access programs.   I resolved those by downloading the Microsoft Access Database Engine 2016.

    While my program functions fine, I can not build after making changes in the program.   The output from build is 

    1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(2604,5): warning MSB3304: Could not determine the dependencies of the COM reference "Microsoft.Office.Interop.Excel1". Element not found. (Exception from HRESULT: 0x8002802B (TYPE_E_ELEMENTNOTFOUND))
    1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(2604,5): warning MSB3305: Processing COM reference "Microsoft.Office.Interop.Excel1" from path "C:\Program Files (x86)\Microsoft Office\Root\Office16\EXCEL.EXE". Type 'IShape' is invalid and may only be partially converted.
    1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(2604,5): warning MSB3305: Processing COM reference "Microsoft.Office.Interop.Excel1" from path "C:\Program Files (x86)\Microsoft Office\Root\Office16\EXCEL.EXE". Type 'IShapeRange' is invalid and may only be partially converted.
    1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(2604,5): warning MSB3305: Processing COM reference "Microsoft.Office.Interop.Excel1" from path "C:\Program Files (x86)\Microsoft Office\Root\Office16\EXCEL.EXE". Type 'Shape' is invalid and may only be partially converted.
    1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(2604,5): warning MSB3305: Processing COM reference "Microsoft.Office.Interop.Excel1" from path "C:\Program Files (x86)\Microsoft Office\Root\Office16\EXCEL.EXE". Type 'ShapeRange' is invalid and may only be partially converted.
    ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

    There are no errors, but are lots of alerts such as Type "IShape' is invalid.   There are warnings about 32 bit and 64 bit.    

    Looking at my MS.Office.Interop.Excel, the version is 15.0.4795.1000 and Access is 15.0.4420.1017.   Under References, MS Access 16.0 Object Library is checked as is MS Excel 16.0 Object Library and MS Office 16.0 Object Library. 

    I have tried many other fixes, but none made progress.

    Friday, June 1, 2018 8:43 PM

Answers

  • Hello jjobcorp,

    >>Microsoft.Office.Interop.Excel1

    Excel1? Did you ever add multiple references to Excel? I would suggest your remove all the references to Microsoft.Office.Interop.Excel and Microsoft.Office.Interop.Excel1 and then add only a single reference to Microsoft.Office.Interop.Excel. 

    Best Regards,

    Terry


    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 MSDNFSF@microsoft.com.

    • Marked as answer by jjobcorp Monday, June 4, 2018 9:17 PM
    Monday, June 4, 2018 2:56 AM

All replies

  • Hello jjobcorp,

    >>Microsoft.Office.Interop.Excel1

    Excel1? Did you ever add multiple references to Excel? I would suggest your remove all the references to Microsoft.Office.Interop.Excel and Microsoft.Office.Interop.Excel1 and then add only a single reference to Microsoft.Office.Interop.Excel. 

    Best Regards,

    Terry


    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 MSDNFSF@microsoft.com.

    • Marked as answer by jjobcorp Monday, June 4, 2018 9:17 PM
    Monday, June 4, 2018 2:56 AM
  • Thanks.   I had already removed excel1, but I had not removed the old one and then reinstalled.   I had to uninstall with NuGet and then reinstall there.    That did it.
    Monday, June 4, 2018 9:19 PM