Implementing master-detail in the DataGrid

In order to save screen space, not creating too many columns in a DataGrid may be a good idea. A better solution in this case is to create a master-detail implementation. The master, being the original row in the DataGrid, would then contain a few columns only. When clicking on any row, the details of that row are shown. In the Silverlight DataGrid, this is possible due to the RowDetailsTemplate.

Getting ready

To follow along with this recipe, you can continue using the code that was created in the previous recipes. Alternatively, you can use the starter solution located in the Chapter04/Datagrid_Master_Detail_Starter folder in the code bundle that is available on the Packt website. The finished solution ...

Get Silverlight 4 Data and Services Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.