This blog shows how to use Webgrid in ASP.NET MVC. It displays model data in WebGrid in PartialView on selection change of Listbox value.
For this tutorial you will create a view with ListBox. Listbox will have a list of categories from Northwind database. On selection of category, products under selected category will be shown in Webgrid. It loads partialview using jQuery to display Webgrid.
-
HTML View - with WebGrid HTML and jQuery functions.
-
Home Controller - with action method to return product list from database.
After you implement code from this repo, you will see the WebGrid rendered like
For more details visit - ASP.NET MVC