GridView in ASP.Net MVC

Posted by Naraayanan under ASP.NET MVC on 10/23/2013 | Points: 10 | Views : 2160 | Status : [Member] | Replies : 4
Hi all,
How to use Grid View (Add, Edit and Delete) using ASP.Net MVC3.

Regards,
Lakshmi Naraayanan.S
http://dotnettechrocks.blogspot.in/
http://abaprocker.blogspot.com/



Responses

Posted by: Bandi on: 10/23/2013 [Member] [MVP] Platinum | Points: 25

Up
0
Down
Refer these links
http://code.msdn.microsoft.com/Detail-CRUD-Operations-fbe935ef
http://www.campusmvp.net/blog/webgrid-in-mvc-3-step-by-step-one

Mark This Response as Answer
--
Chandu
http://www.dotnetfunda.com/images/dnfmvp.gif

Naraayanan, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sheonarayan on: 10/23/2013 [Administrator] HonoraryPlatinum | Points: 25

Up
0
Down
Hi Naraayanan,

There is no GridView in ASP.NET MVC, you can't do it the same way as you used to do in ASP.NET Web Forms.

Here you can do all these things in different pages.

At the time of creating a view, you can create a strongly typed view and select a Model class for it and then use Scaffold template of your choice. (ASP.NET MVC 4).

I am assuming this remain same in ASP.NET MVC 3 as well.

Thanks

Regards,
Sheo Narayan
http://www.dotnetfunda.com

Naraayanan, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sheonarayan on: 10/23/2013 [Administrator] HonoraryPlatinum | Points: 25

Up
0
Down
You can also read this article where Niladri has nicely explains with pictures on how to perform CRUD operation in ASP.NET MVC http://www.dotnetfunda.com/articles/show/2336/let-us-do-basic-crud-using-mvc4-rajor-view.

Thanks

Regards,
Sheo Narayan
http://www.dotnetfunda.com

Naraayanan, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Chandrashekarthota on: 5/19/2014 [Member] Starter | Points: 25

Up
0
Down
Naraayanan,
It depends on your requirement again. There are many ways to achieve Grid view functionality.

1. Using Scaffold Template (Best Option, easy to develop skeleton code)
2. Using Jquery Plugins like datatables (more features, easy implementation, easy ajax paging, Light weight, little bit unsecured)
3. Using GridView with Aspx view (Add view or partial view with aspx engine, use your old school technology, not preferred)
4. We have asp.net webgrid which is simple and tricky :).

I always prefer option number 1 and option 2 in few scenarios and a good place to start would be http://www.asp.net/mvc/tutorials

Chandra Shekar Thota
Founder/Developer
www.hyderabadtechies.info

Naraayanan, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response