Unable to retrieve project metadata. Ensure it's an MSBuild-based .NET Core project

六月ゝ 毕业季﹏ 提交于 2019-12-01 03:52:33

For my case this error was solved by downloading latest dotnet-sdk-2.2.107-win-x64

for VS2017 and then dropping and updating database through cmd:

dotnet ef database drop --force --context <<dbcontext>> -s <<startup project directory>> -p <<project directory>>


dotnet ef database update --context <<dbcontext>> -s <<startup project directory>> -p <<project directory>>

I have tried different solutions to solve this error. Did following change in .csproj file.

Solved this issue for .Net Core by edit .csproj file and removed Import tag and then run ef command again in command line.

Add this parameter to the end of your scaffold command "--msbuildprojectextensionspath".

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!