Today i give you a small lesson in Asp.net MVC.
First of all we get the controller action.
In above action some codepart was missing. So you have to start with your own action. So, you can see at the end of the page i have passed the model to "_ToDoList_LoadActions" view.
It is not enough and you have to catch the model from view as below.
You can see top of the _ToDoList_LoadActions.cshtml file as "@model US.BOX.CreditorPortal.Web.Model.MainActionModel". That's the way to catch the model which are coming from controller to view. But be careful because "MainActionModel" is the type of the data model.
Now you can operate the data model using razor.
* Now i move to other one. That is Passing a data model to controller from view.
Now data model is captured from controller as below.
I think you can practice this with your own actions.
Bye.. Happy Coding!