Cannot enable migrations for Entity Framework in class library

前端 未结 2 1703
滥情空心
滥情空心 2020-12-05 22:21

I just got on board with EF 5 and am using their code-first migrations tool but I seem to get an error when I try to enable migrations.

I type Enable-Migration

2条回答
  •  独厮守ぢ
    2020-12-05 23:16

    Oh wow, nevermind. I'm dumb.

    In the Nuget package manager console there is a dropdown menu at the top labeled "Default Project:". Make sure you set that to the project you want to run the command against.

    Hopefully this helps someone else avoid my embarrassing mistake.

提交回复
热议问题