DataGridViewCell.InheritedState 属性

定义

获取该单元格从它的行和列的状态继承后的当前状态。

C#
[System.ComponentModel.Browsable(false)]
public System.Windows.Forms.DataGridViewElementStates InheritedState { get; }

属性值

DataGridViewElementStates 值的按位组合,表示单元格的当前状态。

属性

例外

该单元格不包含在 DataGridView 控件中,且它的 RowIndex 属性的值不为 -1。

该单元格包含 DataGridView 控件中,且它的 RowIndex 属性的值为 -1。

适用于

产品 版本
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9, 10

另请参阅