Control.SetVisibleCore(Boolean) 方法

定義

將控制項設定為指定的可見狀態。Sets the control to the specified visible state.

protected:
 virtual void SetVisibleCore(bool value);
protected virtual void SetVisibleCore (bool value);
abstract member SetVisibleCore : bool -> unit
override this.SetVisibleCore : bool -> unit
Protected Overridable Sub SetVisibleCore (value As Boolean)

參數

value
Boolean

true 表示將控制項設為可見,否則為 falsetrue to make the control visible; otherwise, false.

備註

您通常會覆寫這個方法,以變更控制項的可見度行為。You would typically override this method to change the visibility behavior of the control.

給繼承者的注意事項

在衍生類別中覆寫 SetVisibleCore(Boolean) 時,請務必呼叫基類的 SetVisibleCore(Boolean) 方法,以強制變更控制項的可見度。When overriding SetVisibleCore(Boolean) in a derived class, be sure to call the base class's SetVisibleCore(Boolean) method to force the visibility of the control to change.

適用於

另請參閱