Visual Studio 2015 Community - 'Visual C++ Project System Package' error
Asked Answered
B

2

20

So, I've been having this problem for a little while now. Frequently when I just try to open any of my projects I get the following error:

---------------------------
Microsoft Visual Studio
---------------------------
The 'Visual C++ Project System Package' package did not load correctly.



The problem may have been caused by a configuration change or by the
installation of another extension. You can get more information by examining the
file 'C:\Users\Q009\AppData\Roaming\Microsoft\VisualStudio\14.0\ActivityLog.xml'.



Restarting Visual Studio could help resolve this issue.



Continue to show this error message?

Opening the activity log reveals the following error:

SetSite failed for package [Visual C++ Project System Package][Object reference not set to an instance of an object.]:{ at Microsoft.VisualStudio.Project.VisualC.VCProjectEngine.VCProjectEngineShim.get_ProjectService() at Microsoft.VisualStudio.Project.VisualC.VCProjectEngine.VCProjectEngineShim.Initialize(IntPtr instResources, Object sp, Object browser, IVCBuildPackageInternal bldPkg)}

In order to 'solve' this I just go to AppData/Local/Microsoft and remove VisualStudio and VSCommon folders. This fixes it for a while allowing me to continue work on my projects. Until the issue randomly decides to come back again.

Again, to clarify the situation. It's not a migration problem or a problem with newly installed packages. I've had this setup for a while now and those projects were created using this very instance of Visual Studio.

Boyette answered 20/3, 2016 at 13:40 Comment(4)
As workaround solution, couldn't you just change your IDE?Bilbo
rmdir /q /s %LOCALAPPDATA%\Microsoft\VisualStudio\14.0\ComponentModelCache, after shutting down your IDE, then restart it. I have this same problem with a solution that uses some (2) VS2010 projects compiled with the v10 toolchain; the solution actually has 80+ projects all-but-two converted to vs2015. Anyway, its a PITA, and MS has known about it but it continues to plague.Foliation
Is it different than removing the entire VisualStudio folder (along with VSCommon)?Boyette
I'm getting this just from opening a source file without having any solution or project loaded.Uzzia
A
21

I get the same error every now and then and not just with C++ projects. The solution varies, but most of the times It's done by deleting the files under the ComponentModelCache, as the comment by WhozCraig suggested:

rmdir /q /s %LOCALAPPDATA%\Microsoft\VisualStudio\14.0\ComponentModelCache

Update:

An extension now exists that clears ComponentCache for VS 2015, 2017, written by Mads Kristensen.

Allimportant answered 5/6, 2016 at 21:25 Comment(2)
Thanks!! this fixed a same problem in Visual Studio 2017Patrinapatriot
You save my vcproj. You are the man! In VS2017 case, you should remove the component cache of VS2017 (Folder 15.0_3734c5e5).Auburta
K
0

for me issue got resolved in VS 2017 community by installing/updating Visual C++ package from Tools of VS

Kendallkendell answered 16/6, 2020 at 10:24 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.