System.Data.Entity. The database could not be found.

asp.net-mvc entity-framework

Question

I can't find DataBase in System.Data.Entity.

Any one know why?

Thank you.

1
18
6/11/2011 12:46:40 PM

Accepted Answer

You dont have to import System.Data.Entity.Database. The System.Data.Entity is enough. Use Database.SetInitializer instead of DbDatabase.SetInitializer.

If you missed it it, the class is called Database without "Db"

22
6/23/2011 12:07:17 PM

Popular Answer

You need to reference the EntityFramework.dll assembly which is where the Database class is declared. You could install it from the corresponding NuGet package.



Related Questions





Related

Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow
Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow