相关疑难解决方法(0)

删除所有DataGrid行和单元格边框

我想隐藏(或删除)我的数据网格中所有行(以及随后的单元格)的所有边框,想一个基本的HTML表.我看了一遍,大多数问题似乎是关于造型而不是隐藏它们.

我已经尝试过像这样设置BorderBrush和BorderThickness:

 <DataGrid.RowStyle>
     <Style TargetType="DataGridRow">
         <Setter Property="BorderBrush" Value="Transparent" />
         <Setter Property="BorderThickness" Value="0" />
     </Style>
  </DataGrid.RowStyle>
Run Code Online (Sandbox Code Playgroud)

为CellStyle尝试了相同,但没有骰子,仍然看到边界.

.net c# wpf xaml datagrid

56
推荐指数
1
解决办法
4万
查看次数

标签 统计

.net ×1

c# ×1

datagrid ×1

wpf ×1

xaml ×1