none
Error while upgrading from .netframework3.5 to .net framework 4.0 office solution..The type or namespace name 'Office' does not exist in the namespace 'Microsoft.VisualStudio.Tools' (are you missing an assembly reference?) RRS feed

  • Question

  • Hi,

    I have done below steps to target the 4.0 from 3.5 framework.

    I have opened the solution using visual studio 2012 and targeted the framework to 4.0 in the properties of solution and updated the event handlers in ribbon class as mentioned in the article.

    When I compiled I got the below error

    The type or namespace name 'Office' does not exist in the namespace 'Microsoft.VisualStudio.Tools' (are you missing an assembly reference?) 

    I have googled with this error then I have downloaded Microsoft.VisualStudio.Tools.Office.Runtime.dll and added as reference to the solution

    When I compiled I got the below error

    The type or namespace name 'IOfficeEntryPoint' does not exist in the namespace 'Microsoft.VisualStudio.Tools.Office' (are you missing an assembly reference?)

    Please let mw know if I am missing anything here.

    Please help me in resolving this error

    Thanks,

    Meenakshi Nagpal


    N.Meenakshi

    Wednesday, January 8, 2014 12:46 PM

Answers

  • Meenakshi,

    If you open the Object Browser window in Visual Studio and try to locate the Office namespace, you can find it in the Office reference as shown on the screenshot:

    So, I'd suggest you to check references of your add-in project. Most probably you need to re-add some of them due to the fact the path may change. Also some references should be added. So, the best way is to create a brand new project with the target framework set in the wizard and find the required references there.

    I have a feeling that you are trying to upgrade the VSTO add-in project (use the latest version of VSTO), not just set the target framework. Am I right?

    • Marked as answer by Marvin_Guo Friday, January 24, 2014 2:17 AM
    Wednesday, January 8, 2014 5:08 PM