Click here to Skip to main content
15,894,720 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello

I am trying out the sample MVC application which is been posted in the link "http://www.asp.net/mvc/tutorials/getting-started-with-mvc3-part4-cs"[^]... As mentioned in the above tutorials I am suppose to derive my class called SchoolContext from the DbContext class available under the namespace System.Data.Entity.

I have set a reference for the System.Data.Entity dll by adding reference to the project , and have also mentioned the line "using System.Data.Entity;" , even then I am not able to derive from the class DbContext and nor even able to use the DbSet .

Please let me know what needs to be done to resolve the same.Please refer the link provided above to see the source code.

Regards
Posted

1 solution

MSDN[^] says you need to add a reference to EntityFramework.dll not "System.Data.Entity dll"
 
Share this answer
 
Comments
touseef4pk 12-Jul-11 7:32am    
Thanks it helped... here my 5 :)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900