304

I installed Visual Studio 2012 and DevExpress 13.1. As Visual Studio started, it generated an error shown by this attached image,

The 'Microsoft.VisualStudio.Editor.Implementation.EditorPackage' 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\must\AppData\Roaming\Microsoft\VisualStudio\11.0\ActivityLog.xml'.

Continue to show this error message?

Microsoft Visual Studio - The 'Microsoft.VisualStudio.Editor.Implementation.EditorPackage' package did not load correctly.

This error also appears in Visual Studio 2017.

6
  • 4
    Read that error carefully: "You can get more information by examining the file ..." - what does that file say?
    – fvu
    Jul 10, 2013 at 15:06
  • @fvu Activity-Log file opening error generated.
    – Dua Ali
    Jul 10, 2013 at 15:20
  • 1
    One thing to check before doing deeper analysis - "Is there enough free space on the disk"?
    – LCJ
    Feb 13, 2017 at 17:52
  • FYI: I had same problem in VS Pro 15.7.x - solution from @dinesh solved it for me.
    – qxotk
    Aug 21, 2018 at 16:16
  • UPDATE: Opened a different project today (1 day after my prior comment above) and received the same error again. Followed the steps in solution from @dinesh below, and error went away. Don't know if it was the steps, or simply opening Visual Studio a second time.
    – qxotk
    Aug 22, 2018 at 13:01

34 Answers 34

538

I started to see this on a fresh Windows and Visual Studio 2013 Ultimate with Update 2 installation (although others have also reported it on Updates 3 and 4, as well as the Professional version).

To resolve the problem, close all Visual Studio instances, then delete all files in the following folder:

Visual Studio 2013

%localappdata%\Microsoft\VisualStudio\12.0\ComponentModelCache

It worked fine for me. Thanks to this article.

Visual Studio 2015

%localappdata%\Microsoft\VisualStudio\14.0\ComponentModelCache

Visual Studio 2017

%localappdata%\Microsoft\VisualStudio\15.0_xxxx\ComponentModelCache

Visual Studio 2019

%localappdata%\Microsoft\VisualStudio\16_xxxx\ComponentModelCache

Visual Studio 2022

%localappdata%\Microsoft\VisualStudio\17_xxxx\ComponentModelCache
15
  • 3
    I'm having the same issue in VS 2015 but there doesn't appear to be any ComponentModelCache folder though. Perhaps it goes by a different name in newer versions of Visual Studio?
    – jpierson
    Jan 23, 2017 at 15:52
  • 5
    @jpierson yes the folder ComponentModelCache for VS 2015 can be found in the folder: 14.0. The full path is as follows: C:\Users\<your user name>\AppData\Local\Microsoft\VisualStudio\14.0\ComponentModelCache
    – w0ns88
    Jan 31, 2017 at 12:37
  • 4
    I'm having this problem on my fresh install of Visual Studio 2017... and again, the folder structure is not the same! Mar 18, 2017 at 6:15
  • 3
    Have added folder that was created for VS 2017, might want to try and see.
    – user_v
    Mar 19, 2017 at 14:43
  • 10
    Worked for Visual Studio 2019: %localappdata%\Microsoft\VisualStudio\16_xxxx Oct 28, 2019 at 8:12
98

I encountered this problem in Visual Studio 2017 (15.7.4). After trying various solutions, eventually this worked for me: close all Visual Studio instances, and run this from the command line (possibly with administrator rights):

devenv.exe /clearcache
devenv /updateconfiguration
14
  • 5
    This worked for me, I think there's an issue with one of the productivity power tools extensions after latest VS update
    – Sean T
    Jul 25, 2018 at 8:19
  • 1
    This worked for me and I ran VS 2015 command prompt in admin mode. +1 Sep 6, 2018 at 9:26
  • 23
    Be sure to start Developer Command Prompt for VS {version}. devenv.exe is most likely not known in your normal CMD (if you haven‘t added it to the path at least). This Developer Command Prompt takes care of that. It was installed with VS and was in the start menu in my case.
    – bugybunny
    Dec 18, 2018 at 10:09
  • 6
    Does anyone know what /updateconfiguration does exactly?
    – bugybunny
    Dec 18, 2018 at 10:14
  • 2
    This worked for me, I have VS2019. Emptying cache or rewriting roaming didn't work for me
    – Fabrice T
    Oct 8, 2020 at 1:05
64
  • Close Visual Studio.

  • Backup and delete the following path:

    C:\Users\{your_username}\AppData\Roaming\Microsoft\VisualStudio\11.0

  • Restart Visual Studio as Admin. Otherwise, the Roaming folder can't be repaired by Visual Studio.

5
  • 2
    This worked with visual studio 2015 community edition also. The path changes to C:\Users\{your_username}\AppData\Roaming\Microsoft\VisualStudio\14.0, but it works just the same. Also, before opening visual studio, I ran the devenv /setup command suggested by @J-B
    – flaria
    Jul 11, 2016 at 20:25
  • 2
    The solution proposed by @user_v is a little less abrasive, as it only deletes the problem folder not the whole thing.
    – Cody
    Jul 19, 2016 at 20:26
  • It worked for me. But After deleting the mentioned files, I run devenv /setup command in Command Prompt for VS2015. It caused the deleted files to be created again. then I run the Visual Studio ;) Jun 20, 2017 at 20:35
  • There was not a VisualStudio folder there for me (VS Pro 2017). I deleted C:\Users\{your_username}\AppData\Local\Microsoft\VisualStudio\15.0_xxxx and started in Administrator mode and it worked. Nov 6, 2018 at 16:08
  • 1
    I was getting this with the "Roslyn" package in Visual Studio 2022. None of the other solutions here worked. This fixed it though
    – Joe
    Oct 28, 2022 at 16:27
34

Try devenv /setup on the Visual Studio Command Prompt with administrative rights.

I had the same problem with Visual Studio 2013 Ultimate. I tried the solution by Reza posted here, but it didn't work.

Eventually I couldn't close Visual Studio. It was showing a similar dialog when I tried to close, and it wasn't closing. I tried this: Error message "No exports were found that match the constraint contract name". Neither.

I noticed a message in the Team Explorer window saying "Page 'somenumber' cannot be found". I tried that way, and I found this answer: Page '312e8a59-2712-48a1-863e-0ef4e67961fc' not found using Visual Studio 2012. So I run devenv /setup on the Visual Studio Command Prompt with administrative rights.

It did the job, and everything is fine now.

4
  • Microsoft does not give lot of details of what devenv /setup does. Just that it is the last step of the installation process. msdn.microsoft.com/en-us/library/ex6a2fad.aspx
    – jbarrameda
    Apr 18, 2014 at 17:33
  • Props for the link to the "constraint contract name" question. That's what actually fixed my issue. Thanks for including it. Mar 22, 2016 at 13:38
  • 4
    In my case devenv.exe /resetuserdata helped. Note: it resets ALL user data.
    – Matty
    Jun 21, 2017 at 11:26
  • I've just had the same issue with VS Professional 16.3.5 and following the instructions in the Error message "No exports were found that match the constraint contract name" link worked for me Oct 17, 2019 at 7:52
19

Solution for Visual Studio 2017:

Step 1: open Visual Studio cmd in administrator mode (see start menu item: Developer Command Prompt for VS 2017 - Be sure to use: Run as administrator)

Step 2: change directory to the folder where Visual Studio 2017 is installed, for example:

cd C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise

(You can copy/paste this command to your cmd prompt. For Visual Studio Professional, the folder will be called "Professional" instead of "Enterprise", etc.)

Step 3: copy/paste the below command

gacutil -if Common7\IDE\PublicAssemblies\Microsoft.VisualStudio.Shell.Interop.8.0.dll

Hit Enter...

It will resolve the issue...

Otherwise, you can also add the following to the GAC as above:

Microsoft.VisualStudio.Shell.Interop.9.0.dll

Microsoft.VisualStudio.Shell.Interop.10.0.dll

Microsoft.VisualStudio.Shell.Interop.11.0.dll

7
  • 1
    I have had several Visual Studio projects show this error, and each time I repeated the steps above to solve it.
    – qxotk
    Aug 23, 2018 at 21:33
  • This solved my problem. We just upgraded our source from 2015 with 4.6.2 to 2017 with 4.7.1. I just started getting this problem and this is the solution that worked for me. Thanks for the fix!
    – Osiris
    Sep 6, 2018 at 17:00
  • This is the only thing that worked for me after trying everything else above. Thanks!
    – Martin
    Sep 17, 2019 at 15:29
  • 3
    In 2019 you need to add Microsoft.VisualStudio.Shell.Interop.12.0.dll
    – HackSlash
    Feb 7, 2020 at 20:35
  • I tried 15+ solutions. Only this answer has some magic. Apr 12, 2021 at 15:57
16

I had a similar problem, and I went to Control PanelPrograms and repaired the Visual Studio installation. It worked for me.

2
  • 2
    Tried 2 of above solutions for the same error but for SpecFlow package, it did not work. This worked for me. The solutions I tried: 1: Removing ComponentModelCache 2: Removing AppData\Roaming\Microsoft\VisualStudio\11.0
    – Brampage
    Mar 6, 2018 at 8:58
  • 2
    You can't repair Visual Studio 2017 from Control Panel, you have to navigate to C:\Program Files (x86)\Microsoft Visual Studio\Installer where you can find the vs_installer.exe file.
    – Brampage
    Mar 6, 2018 at 9:00
4

I had the same problem. Try to remember the latest extension that you installed. I delete the latest extension from extensions and updates and restart Visual Studio. and the problem is solved. For me, the extension name is Productivity Power Tools

3

I had a similar issue (Tizen Project type package did not load correctly) with Visual Studio 2017.

After trying all the answers above, and spending a few hours searching for a solution for the errors inside ActivityLog.XML, nothing worked for me.

Eventually, the solution was a Visual Studio Repair.

I assume that the repair process overrides some configurations that caused the problem.

Repair Visual Studio 2017
Repair Visual Studio 2019

1
  • This worked for me with VS 2019. I ran the repair process, rebooted, and the error went away.
    – daGUY
    Jan 21, 2022 at 18:16
2

I also experienced this issue after installing Telerik Reporting. I was not able to launch any solution in Visual Studio 2013, nor could I close Visual Studio 2013.

After uninstalling the reporting package and deleting Local / Roaming AppData for Visual Studio 2012, the problem was fixed.

2
  • 1
    Got a heap of similar errors recently. I was evaluating DevExpress components during last three weeks. So I uninstalled DevExpress, the error messages are gone. Not sure if DevExpress caused the problem though
    – Alex Klaus
    Feb 26, 2014 at 0:14
  • 1
    In my case I reinstalled devexpress and all worked ok after that
    – rasputino
    Nov 17, 2014 at 14:18
2

In my case the error message is "The 'IntelliCodeCppPackage' package did not load correctly" (Visual Studio 2019):

IntelliCodeCppPackage

I solved this is issue with these steps;

2

I tried everything except the repair. I even did an update. This is what fixed it for me:

  1. Open "Developer Command Prompt for VS 2017" as Admin
  2. CD into (your path may vary) CD C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\PublicAssemblies
  3. Run command gacutil -i Microsoft.VisualStudio.Shell.Interop.11.0.dll
  4. Restart Visual Studio
1
  • A much better version of this answer was already posted 2 years before this: stackoverflow.com/a/51588427/3873799. Please do not add noise with redundant answers. This issue is already messy as it is.
    – alelom
    Mar 23 at 8:34
1

Based on this Connect feedback I fixed it by closing all opened documents and restarting Visual Studio. I use Visual Studio 2015.

1

You need to find file devenv.exe.config in C:\Users\{user_name}\AppData\Local\Microsoft\VisualStudio\14.0\ and update it. (Or C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\, depending on the location of your devenv.exe file.)

For this particular case, you should find rows that setup redirects for System.Collections.Immutable and change newVersion from 1.1.36.0 to 1.1.37.0.

The original article is How to restore Visual Studio 2015 after the Update 1 (dependency dance).

1

I had this problem, and projects were not loading correctly or stating that they needed migration. The ActivityLog.xml showed an error with a particular extension. I uninstalled the extension and restarted Visual Studio. That resolved the issue.

1

I also experienced the same error, "NPM package not installed correctly", while creating a Node.js project in Visual Studio 2015.

I resolved my issue by performing two steps:

  1. Delete all files present in this location:

    C:\Users\<Your User Name>\AppData\Local\Microsoft\VisualStudio\14.0\ComponentModelCache
    

    Restart Visual Studio.

  2. Open Visual Studio and go to menu ToolsNuGet Package ManagerPackage Manager Settings

    On the left side: You will see a drop down list: select Node.js, ToolsNpmClearCache → *OK

Then again try to create the project. It resolved my issue.

1

I had the pleasure of experiencing this random problem in Visual Studio 2017 Enterprise.

I tried every solution here, and it didn't work, including the Visual Studio repair (which takes a while). Several hours in, I thought maybe I should actually check the ActivityLog.xml file.

ActivityLog.xml

I uninstalled the offending extension from the 'Developer Command Prompt for VS2017' as an administrator since Visual Studio just freezed after open and nothing could be clicked.

Steps to uninstall - courtesy of jessehouwing.net

  1. Find the vsix file you used to install the extension.
  2. Open it in your favorite archiver (mine is 7-Zip).
  3. Grab the extension's Id from the Identity node from the extension.vsixmanifest.
  4. Run (in my case) vsixinstaller /u:Microsoft.VisualStudio.LiveShare to remove the extension.
1
  1. Find the ComponentModelCache folder
  2. Delete Microsoft.VisualStudio.Default.cache
  3. Restart Visual Studio

Enjoy using Visual Studio.

1

I had a similar problem.

After checking ActivityLog.xml and it said that it could not create an instance for the Extension/package name from a specific folder. I traced that path and I didn't find that folder it is looking for.

So I installed the extension again, I looked for the dll, and copied the containing folder contents to the folder Visual Studio is looking for.

So to recap:

  1. Check if the folder in the error exists
  2. If not, create a new folder with the same name
  3. Look for the dll in the error in the Visual Studio folder, if not found, install the extension again
  4. If the error resists, search inside the Visual Studio folder in Program Files (x86) for the dll and open the containing folder
  5. Copy all the contents
  6. Paste inside the new folder you have created with the name mentioned inside the ActivityLog.xml
1

Firstable, you need to be sure have the last Microsoft .NET Framework version, in my case, I had the 4.6 version and I have downloaded and updated the .NET Framework 4.8.03761 Developer Pack, from the official site:

https://dotnet.microsoft.com/download/dotnet-framework/net48

Once I restarted my PC, to continue fixing that, I solved this problem by clearing Visual Studio Component Model Cache.

Just delete or rename this folder:

%LocalAppData%\Microsoft\VisualStudio\11.0\ComponentModelCache or

%LocalAppData%\Microsoft\VPDExpress\11.0\ComponentModelCache and restart Visual Studio.

1
  • that actually did it for me on VS 2022. Solution by tdracz was not enough. Same solution as most upvoted by user_v Nov 25, 2021 at 14:01
1

Since this is the top SO result in google for this issue, I'm going to leave my fix here for VS 2022 when experiencing this issue. I found it is commonly caused by an extension issue. In my particular case TypeScript Definition Generator was causing the issue and removing the extension solved it. To find which extension could be causing the issue, run VS with the /Log command line switch.

i.e.: "C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\IDE\devenv.exe" /Log

After the error occurs, close VS and locate ActivityLog.xml found at %AppData%\Microsoft\VisualStudio\<version>\ActivityLog.xml. Search the log for any extensions reporting an error and uninstall it.

0

I just wanted to mention that I got a similar error in SQL Server Management Studio 2016, where I basically ignored it. Later, I launched Visual Studio (2015), and this error occurred there as well.

I searched and found the answer here recommending that files be deleted from the

%localappdata%\Microsoft\VisualStudio\14.0\ComponentModelCache

folder. However, in my case, this folder was empty.

Since I remembered that I saw the error in Management Studio first, I checked, and there was a similar folder at

%localappdata%\Microsoft\SQL Server Management Studio\13.0\ComponentModelCache

This folder was not empty. I closed both Visual Studio and Management Studio, and deleted the files from this folder.

Afterwards, both Management Studio and Visual Studio launched without error.

0

I had this problem after installing Crystal Reports for Visual Studio. I solved it by closing all Visual Studio instances and reinstalling Crystal Reports.

0

I solved it:

  1. Go to install
  2. Modify
  3. Go to "Installation location" tab
  4. Check "keep download cache after the installation"
  5. Modify
0

My issue was Mysql connector net 6.4.4, Nuget, xamarin, VSPackage, EditorPackage and etc.. package did not load correctly.

My solution is below for vs2015

  1. Open AppData location // all the configurations are updating on it.
  2. Backup and Remove the folder in which configuration error is thrown in the visual studio.

forex. If you have Nuget package did not load correctly error - Remove Nuget folder in Local and Roaming directories.

  1. And also clear the data on AppData/Microsoft/visual Studio/14.0 for vs2015

that's it and it worked for me!...

0

For Visual Studio 2019: I have done the following things to solve the problem

Backup the following Folder. After Taking backup and Delete This Folder C:\Users\munirul2537\AppData\Roaming\Microsoft\VisualStudio\16.0_add0ca51

Go to the installation panel of visual studio and do the following things

1.Go to install 2.Modify 3.Go to "Installation location" tab 4. Check "keep download cache after the installation" 5. Modify

0

For Visual Studio 2017, 2019. I got this error and able to fix it just by enable the Live Share extension from extensions.

see the VS community page for detail.

0

For others that have a similar problem but with live share.

In the visual studio installer there was a warning that live share was not installed correctly and a modification was pending, that would download live share again.

After completion of the modification the error was resolved.

0

I had the same problem for Visual Studio 2019 v16.8.6. It was fixed after repair Visual Studio from Visual Studio Installer.

0

One more solution that worked for my colleague after trying all the others that did not work (for Visual Studio 2022).

Try this:

  1. Close all instances of Visual Studio
  2. Go to: C:\Program Files (x86)\Microsoft SDKs\Windows
  3. You should see a number of vX.0-like directories (e.g. v10.0A for Visual Studio 2022 Enterprise). Back-up and remove all those directories except the one matching your Visual Studio (in my case I'd remove everything except v10.0A).
  4. Start Visual Studio. The "package did not load correctly" warning will be gone.

Rationale: If you had older versions of Visual Studio installed previously, they will come with their own NETFX Tools which might not uninstall correctly together with those older instances of Visual Studio. The new Visual Studio will for some reason pick the old Tools and fail using them. Removing the redundant directories fixes it.

0

I met this problem. This is how I resolved it:

  1. Firstly, I deleted AppData\Local\Microsoft\VisualStudio\17.0_d1adb3fb/ComponentModelCache, and launch Visual Studio 2022, and other window popup.
  2. Secondly, I deleted the ComponentModelCache again. No error occurred, but the extension is empty.
  3. Finally, I upgraded VS 2022 to 17.2.5, the problem was solved.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.