Click here to Skip to main content
15,886,067 members
Please Sign up or sign in to vote.
1.00/5 (5 votes)
See more:
http://msdn.microsoft.com/en-us/data/jj554735.aspx
I tried before but couldn't get it to work.
Posted
Comments
Sergey Alexandrovich Kryukov 12-Mar-14 12:40pm    
Not a question.
—SA
AnvilRanger 12-Mar-14 12:42pm    
"I tried before but couldn't get it to work." is very vague. What did work? What errors did you see? What code did you try?

There are literally thousands of examples on Code First and Migrations. Just search Google.

Then get a book on it, here[^].

There is no way you're going to get a full tutorial on how to do it from a forum or a couple of articles. There's just WAY too much information to cover.
 
Share this answer
 
you can do that in a simple console application. Add respective classes required for your application and then apply reverse engineering. You will get all the required logic to understand. Else you can try with MVC application also add your classes and then use CRUD operation that is use schaffolded controller. This will generate all the actions and view as required for the classes specified. Dont forget to create a DbContext class to store DbSet<> properties of the classes.

Hope this helps
Thanks
 
Share this answer
 

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