DataGridViewCellStyle.IsNullValueDefault 屬性

定義

取得指出是否已經設定 NullValue 屬性的值。Gets a value indicating whether the NullValue property has been set.

public:
 property bool IsNullValueDefault { bool get(); };
[System.ComponentModel.Browsable(false)]
public bool IsNullValueDefault { get; }
[<System.ComponentModel.Browsable(false)>]
member this.IsNullValueDefault : bool
Public ReadOnly Property IsNullValueDefault As Boolean

屬性值

Boolean

如果 NullValue 屬性的值是預設值,則為 true,否則為 falsetrue if the value of the NullValue property is the default value; otherwise, false.

屬性

備註

您可以使用這個屬性來判斷 NullValue 屬性是否已明確設定,而不需要儲存其預設值進行比較。Use this property to determine whether the NullValue property has been explicitly set without having to store its default value for comparison. 這項功能很有用 NullValue ,因為屬性具有非空白的預設值,與其他 DataGridViewCellStyle 具有預設值的其他屬性(例如 nullEmpty 或)不同 NotSetThis is useful because the NullValue property has a non-empty default value, unlike most other DataGridViewCellStyle properties, which have default values such as null, Empty, or NotSet.

適用於

另請參閱