Gets or sets a property name, or a period-delimited hierarchy of property names, that indicates the member to sort by.
Assembly: System.Windows.Controls.Data (in System.Windows.Controls.Data.dll)
In columns that are derived from DataGridBoundColumn, such as DataGridTextColumn and DataGridCheckBoxColumn, the is set to the property that the column is bound to through the Binding property by default. In columns that are derived from DataGridColumn, such as DataGridTemplateColumn, the property must be set to enable automatic sorting of the column.
The following code example demonstrates how to set the property. This example is part of a larger example available in the How to: Customize Auto-Generated Columns in the DataGrid Control topic.
// Create a new template column. DataGridTemplateColumn templateColumn = new DataGridTemplateColumn(); templateColumn.Header = "Due Date"; templateColumn.CellTemplate = (DataTemplate)Resources["dueDateCellTemplate"]; templateColumn.CellEditingTemplate = (DataTemplate)Resources["dueDateCellEditingTemplate"]; templateColumn.SortMemberPath = "DueDate";
For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.