如何自定义 DataGrid 标头?这张照片显示了我想做的事情......
我试试这个,但它不起作用......
<DataGridTemplateColumn.Header>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition></ColumnDefinition>
<ColumnDefinition></ColumnDefinition>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="*"></RowDefinition>
</Grid.RowDefinitions>
<TextBlock Grid.Column="0" Grid.Row="0" Grid.ColumnSpan="2" Text="Název modelu"></TextBlock>
<TextBlock Grid.Column="0" Grid.Row="1" Text="Cena bez DPH"></TextBlock>
<TextBlock Grid.Column="1" Grid.Row="1" Text="Cena s DPH"></TextBlock>
</Grid>
</DataGridTemplateColumn.Header>
你能帮我吗,我该怎么做?