Entity Framework를 사용하여 ASP.NET MVC5에 대해 배우고 있습니다.ASP.NET MVC Nuget Enabling-Migrations
: 나는 그것을 내가 folowin 오류가 발생했습니다 실행 한 후Enable-Migrations -ContextType ApplicationDbContext Exception calling "LoadFrom" with "1" argument(s): "Could not load file or assembly 'file:///C:...\Projects\Lynda MVC - Exercise Files\Ch3 - continue\Start\packages\EntityFramework.6.1.1\tools\EntityFramework.PowerShell.Utility.dll' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)" At C:...\Projects\Lynda MVC - Exercise Files\Ch3 - continue\Start\packages\EntityFramework.6.1.1\tools\EntityFramework.psm1:780 char:5 + $utilityAssembly = [System.Reflection.Assembly]::LoadFrom((Join-Path $ToolsP ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [], MethodInvocationException + FullyQualifiedErrorId : FileLoadException You cannot call a method on a null-valued expression. At C:...\Projects\Lynda MVC - Exercise Files\Ch3 - continue\Start\packages\EntityFramework.6.1.1\tools\EntityFramework.psm1:781 char:5 + $dispatcher = $utilityAssembly.CreateInstance( + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : InvalidOperation: (:) [], RuntimeException + FullyQualifiedErrorId : InvokeMethodOnNull Exception calling "CreateInstanceFrom" with "8" argument(s): "Could not load file or assembly 'file:///C:...\Projects\Lynda MVC - Exercise Files\Ch3 - continue\Start\packages\EntityFramework.6.1.1\tools\EntityFramework.PowerShell.dll' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)" At C:...\Projects\Lynda MVC - Exercise Files\Ch3 - continue\Start\packages\EntityFramework.6.1.1\tools\EntityFramework.psm1:809 char:5 + $domain.CreateInstanceFrom( + ~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [], MethodInvocationException + FullyQualifiedErrorId : FileLoadException
Enable-Migrations -ContextType ApplicationDbContext
: 다음 코드를 실행하기 위해 내가 어디로 내 학습을 위해 나는 린다 비디오 자습서를 사용하고 있는데 나는이 Nuget 콘솔에 붙어
어떤 해결책으로도 도움을받을 수 있다면 큰 도움이 될 것입니다.
가능한 복제본 [EF 4.3.1에서 마이그레이션을 가능하게하려고 시도했을 때 예외가 발생했습니다.] (http://stackoverflow.com/questions/10999561/exception-raised-when-im-trying-enable-migrations-in -ef-4-3-1) – markpsmith