This example illustrates how to define dxDropDownBox with an embedded dxDataGrid for editing data in MVC via an EditCellTemplate. Run the example and check the State column to see this approach in action.
For a client-side solution, please refer to the dxDataGrid - How to use dxDropDownBox as a column editor in edit mode example.
Click the "Show Implementation Details" link to see step-by-step instructions.
Perform the following steps to complete this task:
1. Use EditCellTemplate to define MVC DropDownBox for a required column.
2. Implement the Template function to define MVC DataGrid and handle its selectionChanged event to pass selected keys to DropDownBox. In addition, handle the dxDropDownBox.valueChanged event to adjust the DataGrid selection
3. Use CellTemplate to covert an array of selected keys to a human-readable text.
For more information about MVC templates, please review the Implementing Templates help topic.