visual studio - Studying tutorials for ASP.NET MVC2, struggling to apply to bigger problem -


I am starting ASP.NET MVC2 by going through some tutorials, but this is all very basic when implementing it Let's try my real world problem.

I am following a tutorial based on a simple table database. I ado I create a data model using the Net unit data model and select to generate the model from the database. Then I make a controller for the table, whatever I do in the controller is the list of items, that is

  Personal Sample DatabaseDBEntities _dataModel = New Sample Database DBETT (); Public Performance Index () {Return View (_dataModel.TheOnlyTable.ToList ()); }  

So I'm trying to figure out how to start, when the schema is more complex.

Say that I have fruithop and there is a vegetable in it that references any value from another table (for example color).

Obviously the generated generated code will not work:

   

Because I need to look for value based on samples, on the second table (for example, the color of the vegetables table)

This table In fact, I just tried to return (_dataModel.Table.ToList ()); But nothing seems to be displayed at all, because the context of most areas is somewhere else.

How can I start thinking about these matters? Is there a tutorial / guide that you know will help me get started?

Thanks

The best place to learn:

View and View Models -

Try following this Music Store app.

There is also stupid dinner:


Comments

Popular posts from this blog

Eclipse CDT variable colors in editor -

AJAX doesn't send POST query -

wpf - Custom Message Box Advice -