How can I able to put a title to my datagrid in WPF . All I can do is style my column headers but putting a title for my whole table is impossible for me. Can anyone help me out. Here's the image of the table I want to have.

here is a sample
<DockPanel LastChildFill="True">
<TextBlock Text="Details per Check Type"
Background="Red"
Foreground="White"
FontSize="20"
FontWeight="SemiBold"
TextAlignment="Center"
DockPanel.Dock="Top" />
<DataGrid />
</DockPanel>
above example use a DockPanel as the main container and a TextBlock on the top as the heading and DataGrid in rest of the area.
I give a sample style, you may style the header as desired
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With