DataGridViewCell.Selected 屬性

定義

取得或設定值,指出是否已選取此儲存格。Gets or sets a value indicating whether the cell has been selected.

public:
 virtual property bool Selected { bool get(); void set(bool value); };
[System.ComponentModel.Browsable(false)]
public virtual bool Selected { get; set; }
[<System.ComponentModel.Browsable(false)>]
member this.Selected : bool with get, set
Public Overridable Property Selected As Boolean

屬性值

Boolean

如果已選取儲存格,則為 true,否則為 falsetrue if the cell has been selected; otherwise, false.

屬性

例外狀況

設定此屬性時,沒有相關聯的 DataGridViewThere is no associated DataGridView when setting this property.

-或--or- 設定此屬性時,會共用主控資料列。The owning row is shared when setting this property.

適用於

另請參閱