37

I believe Entity Framework 6 is intended for .NET 4.5. I'm wanting to use it for a Visual Studio 2010 project, so .NET 4.5 isn't available.

Does it support .NET 4.0 and hence Visual Studio 2010?

Sam
  • 40,644
  • 36
  • 176
  • 219
  • 1
    Since all major Windows release supports .NET 4.5 (XP/Server 2003 are going to phase out soon), there is little hope for EF 6 to support non-.NET 4.5. Visual Studio 2013 is going to launch in only a few days, so Visual Studio 2010 becomes "too old". – Lex Li Oct 08 '13 at 05:09

3 Answers3

49

Entity Framework 6 does support .NET 4.0. You should update your version of NuGet then try again. You can find the download at http://www.nuget.org/. I successfully downloaded EntityFramework 6.0.0-rc1 from the main nuget.org feed from an application targeting .NET 4.0

lukew
  • 880
  • 7
  • 8
  • 1
    You're right! I think I got this mixed up with Enterprise Library 6. This isn't the first time I've done that! – Sam Oct 10 '13 at 22:48
  • Beware that .NET 4.0 implementation of EF6 (example 6.1.3) does not seem to implement some async components like IDbAsyncEnumerable which seems to be available when your project targets .NET 4.5 or later. For further info check http://stackoverflow.com/a/40295378/378115 – Julio Nobre Oct 27 '16 at 22:50
2

Entity Framework Version History

EF6 This release can be used in Visual Studio 2013, Visual Studio 2012 and Visual Studio 2010 (runtime only) to write applications that target .NET 4.0 and .NET 4.5.

user3093178
  • 91
  • 1
  • 2
1

As of writing, on October 2018, latest EF 6.2.0 still supports .NET 4.0 and works very fine in Visual Studio 2010.

Boris Zinchenko
  • 2,142
  • 1
  • 24
  • 34