Enable-Migrations-无法将参数绑定到参数"Path" [英] Enable-Migrations - Cannot bind argument to parameter 'Path'
本文介绍了Enable-Migrations-无法将参数绑定到参数"Path"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我是ASP.NET的新手,正在尝试使用实体框架设置webAPI c#应用程序.但是,当我尝试在nuget-package-manager控制台上运行Enable-Migrations命令时,出现以下错误:
I'm new to ASP.NET and am trying to set up a webAPI c# application with entity framework. But when I try to run the Enable-Migrations command on nuget-package-manager console, I'm getting the following error:
无法将参数绑定到参数'Path',因为它为空"
"Cannot bind argument to parameter 'Path' because it is null"
enable-migrations : Cannot bind argument to parameter 'Path' because it is
null.
At line:1 char:1
+ enable-migrations -ContextTypeName SchoolDBContext
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidData: (:) [Enable-Migrations],
ParameterBindingValidationException
+ FullyQualifiedErrorId :
ParameterArgumentValidationErrorNullNotAllowed,Enable-Migrations
我尝试卸载并重新安装实体框架,但仍然会出现相同的错误.
I've tried uninstalling and re-installing entity framework but it still gives the same error.
我该如何解决?
推荐答案
在使用EntityFramework 6.3.0时出现此错误,将其降级为6.2.0可以解决我的问题.
I had this error when using EntityFramework 6.3.0, downgrading it to 6.2.0 fix my issue.
这篇关于Enable-Migrations-无法将参数绑定到参数"Path"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文