运行所选代码生成器时发生错误:无法加载文件或程序集Microsoft.EntityFrameworkCore,版本= 2.0.1.0 [英] There was an error running the selected code generator: Could not load file or assembly Microsoft.EntityFrameworkCore, version = 2.0.1.0
问题描述
当我用MVC Controller with views, using Entity Framework
创建Controller
和View
时,出现了错误.
When I was creating a Controller
and a View
by MVC Controller with views, using Entity Framework
I got an error.
错误是:
运行选定的代码生成器时发生错误:无法 加载文件或程序集Microsoft.EntityFrameworkCore,版本= 2.0.1.0,Culture = neutral,PublicKeyToken = adb9793829ddae60',找到的程序集的清单定义与程序集引用不匹配
There was an error running the selected code generator: 'Could not load file or assembly Microsoft.EntityFrameworkCore, version = 2.0.1.0, Culture=neutral, PublicKeyToken=adb9793829ddae60' the located assembly's manifest definition does not match the assembly reference
使用Entity Framework创建带有视图的MVC Controller:
Creating MVC Controller with views, using Entity Framework:
我该如何解决这个问题?
How can I solve this problem?
我使用Visual Studio Version 15.5.2
,而Microsoft.AspNetCore.All
的版本是2.0.0
推荐答案
我将Microsoft.AspNetCore.All
更新为version 2.0.3
,现在它确实可以正常工作.
I updated the Microsoft.AspNetCore.All
to version 2.0.3
and now it does work right.
这篇关于运行所选代码生成器时发生错误:无法加载文件或程序集Microsoft.EntityFrameworkCore,版本= 2.0.1.0的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!