Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VS2017 The operation failed as details for project could not be loaded

I edit the project.csproj. and re-open the solution the errors occurred: The operation failed as details for project xxx could not be loaded

I try delete obj & bin folder, clear the nuget cache by tool>options. but the error still exist.

Remark: the error do not occur each time, i just restart the project three times. the first and second is correct. but the third the error occur

vs2017: Microsoft Visual Studio Community 2017 Version 15.0.26228.9 D15RTWSVC Microsoft .NET Framework Version 4.6.01586

Package Manager Console Host Version 4.0.0.2323

like image 569
Cuiqs Avatar asked Mar 23 '17 09:03

Cuiqs


4 Answers

I've faced the problem several times, and all but one were solved by just closing and then restarting visual studio 2017. So if you've not, please try restarting VS, then if that fails, look for more serious solutions.

like image 152
Alireza Avatar answered Nov 11 '22 04:11

Alireza


I've just had the same problem. Microsoft are apparently aware of the problem and have fixed in the preview of the next release, see the following comment for details:

https://developercommunity.visualstudio.com/comments/31393/view.html

In the meantime, the workaround is to open VS2017 (without loading your solution), open the Package Manager Console, wait for it to fully load, then open your solution.

like image 28
Andrew Trevers Avatar answered Nov 11 '22 05:11

Andrew Trevers


I came across the same issue in VS 2017 with lastest .NET SDK updates. But here is a quick and easy fix that i was able to find.

While your project is open, open your 'Package Manager Console' and then run 'dotnet restore' command.

In the Package Manager Console window, make sure 'Package Source' dropdown on the top is set to 'All' and 'Default Project' is set to your project name

like image 16
Abdi Avatar answered Nov 11 '22 04:11

Abdi


Just restarting Visual Studio 2017 can be enough to resolve this.

like image 5
robyaw Avatar answered Nov 11 '22 04:11

robyaw