Using the example provided in codeproject I am struggling to work out where I can find the reference to the library Microsoft.Office.Core.
I am getting the error \"
None of the above answer helped me, i was using Visual Studio 2017. What I did is, installed Office/SharePoint Development using Visual Studio Installer.
After that, I was able to see 'office', this assembly contains Microsoft.Office.Core.
Hope this helps you.
If you are not able to find PIA for Office 2013 then follow these steps:
- Click on Solution Explorer in Visual Studio
- Right click on your project name (not solution name)
- Select 'Manage Nuget packages'
- Click on Browse and search for PIA 2013, choose the shown PIA and click on Install.....
And you are done.
You can add reference of Microsoft.Office.Core
from COM components tab in the add reference window by adding reference of Microsoft Office 12.0 Object Library
. The screen shot will shows what component you need.
If someone not have reference in .NET . COM (tab) or not have office installed on machine where visual was installed can do :
Add references from:
C:\Program Files (x86)\Microsoft Visual Studio 11.0\Visual Studio Tools for Office\PIA\Office15
You can use this NuGet package which includes the interop assemblies in addition to the office assembly.
https://www.nuget.org/packages/Bundle.Microsoft.Office.Interop/
I faced the same problem when i tried to open my old c# project into visual studio 2017 version. This problem arises typically when you try to open a project that you made with previous version of VS and open it with latest version. what i did is,i opened my project and delete the reference from my project,then added Microsoft outlook 12.0 object library and Microsoft office 12.0 object libraryMicrosoft outlook 12.0 object library