Regarding MVC View
-
Hi, As i am newbie to asp.net mvc i would like to know the best practices to solve below scenario. In a user profile page i have list of interest. These data is populated from "Interest" table. Which should be displayed as below. Name : [ Text box ] ....
Interest:
Interest 1 O Yes O NO
Interest 2 O Yes O NO
Interest 3 O Yes O NO
Interest 4 O Yes O NO..... Where Yes/No is option button, Where user can select interest. While submitting these values need to be stored in "User_Interest" table. where values in other controls are stored values in "User" table. Technologies using : MVC,Jquery, Linq My Questions are: 1. How to use same view for Create/Edit 2. How to identify and save selected interests 3. How to set previously selected Interest while editing. 4. best way to create view model. If you can point me similar examples that would be great. Thanks in advance
-
Hi, As i am newbie to asp.net mvc i would like to know the best practices to solve below scenario. In a user profile page i have list of interest. These data is populated from "Interest" table. Which should be displayed as below. Name : [ Text box ] ....
Interest:
Interest 1 O Yes O NO
Interest 2 O Yes O NO
Interest 3 O Yes O NO
Interest 4 O Yes O NO..... Where Yes/No is option button, Where user can select interest. While submitting these values need to be stored in "User_Interest" table. where values in other controls are stored values in "User" table. Technologies using : MVC,Jquery, Linq My Questions are: 1. How to use same view for Create/Edit 2. How to identify and save selected interests 3. How to set previously selected Interest while editing. 4. best way to create view model. If you can point me similar examples that would be great. Thanks in advance
I think you are getting confused by the technology. It isn't that difficult. There are many examples that show how to exchange data between controllers and views, what research have you done so far? Have you looked here, http://www.asp.net/mvc[^]?
I know the language. I've read a book. - _Madmatt
-
I think you are getting confused by the technology. It isn't that difficult. There are many examples that show how to exchange data between controllers and views, what research have you done so far? Have you looked here, http://www.asp.net/mvc[^]?
I know the language. I've read a book. - _Madmatt
Hi Mark, Thanks for your reply. I just stepped into MVC 1 day before for a project that needs quick completion. In the mean time i am trying to learn it in-depth. Yes i am little bit confused on the approach on Radio button list scenario in MVC not on how view and controller works. I like the approach in below link. http://robtennyson.us/post/2009/03/08/ASPNET-MVC-Default-Model-Binder-with-Lists.aspx[^] But haven't had got a clear idea on gathered these information on a jquery(on button click) and pass to controller as ajax call. In the controller Add newly selected item .. and delete old item View -- JQuery -- Controller Hope you got my scenario
-
Hi Mark, Thanks for your reply. I just stepped into MVC 1 day before for a project that needs quick completion. In the mean time i am trying to learn it in-depth. Yes i am little bit confused on the approach on Radio button list scenario in MVC not on how view and controller works. I like the approach in below link. http://robtennyson.us/post/2009/03/08/ASPNET-MVC-Default-Model-Binder-with-Lists.aspx[^] But haven't had got a clear idea on gathered these information on a jquery(on button click) and pass to controller as ajax call. In the controller Add newly selected item .. and delete old item View -- JQuery -- Controller Hope you got my scenario
If something this simple confuses you,
<%= Html.RadioButton("model.Value", "RadioBtn", true) %>
I'm sorry for the client. http://haacked.com/archive/2008/07/29/super-simple-mvc-ajax-with-jquery-demo.aspx[^]
I know the language. I've read a book. - _Madmatt