The previous answers are mostly correct, however I find them too complicated or considering only one of the two publishing issues.
First, you can always set the SortPath property to save the sort for the DataGridTemplateColumn or, possibly, to sort a property other than the displayed one.
Secondly, you do not need a DataGridTemplateColumn to have a hint in the column header, as indicated in the OP. You can use the template column if you want to add a tooltip to the actual cell (but this is probably not necessary either). In any case, adding a tooltip to the column heading is most easily done using the HeaderStyle element
<DataGridTextColumn Header="Test" Binding="{Binding TestText}"> <DataGridTextColumn.HeaderStyle> <Style TargetType="DataGridColumnHeader"> <Setter Property="ToolTip" Value="Test ToolTip" /> </Style> </DataGridTextColumn.HeaderStyle> </DataGridTextColumn>
source share