This example illustrates how to implement the master detail GridView with editing capabilities.
Perform the following steps to define the master-detail layout:
1) Define both master and detail GridView settings within separate PartialView files (see the Using Callbacks);
2) Set the master grid's SettingsDetail.ShowDetailRow property to "True";
3) Define the master grid's DetailRow content via the SetDetailRowTemplateContent method and render the detail grid's PartialView inside.
Note:
Values passed in a detail grid's CallbackRoute must have a unique name and must not replicate any other names on a page: Q577974: GridView - "The parameters dictionary contains a null entry for parameter 'id' of non-nullable type 'System.Int32'" error occurs when canceling editing in the detail GridView
See also:
GridView - Advanced Master-Detail View
A simple example of master-detail grids with editing capabilities
Question Comments
Added By: Wilson Vargas at: 10/20/2012 12:08:04 PM
This sample not compile!
settings.DataBinding = (sender, e) => {
((MVCxGridView)sender).ForceDataRowType(typeof(DevExpress.Razor.Models.Person));
Excellent - just what I needed!
Added By: Paul Astro at: 8/27/2014 12:21:12 PMHello Support,
Is there a ASP.NET version for this exact same example? Please supply URL link...... thanks.
Added By: Anthony (DevExpress Support) at: 8/27/2014 11:49:39 PM Hello,Please refer to the A simple example of master-detail grids with editing capabilities example.