Control.SetTopLevel(Boolean) メソッド
定義
コントロールをトップレベル コントロールとして設定します。Sets the control as the top-level control.
protected:
void SetTopLevel(bool value);
protected void SetTopLevel (bool value);
member this.SetTopLevel : bool -> unit
Protected Sub SetTopLevel (value As Boolean)
パラメーター
- value
- Boolean
コントロールをトップレベル コントロールとして設定する場合は true
。それ以外の場合は false
。true
to set the control as the top-level control; otherwise, false
.
例外
value
パラメーターが true
に設定されていて、コントロールが ActiveX コントロールです。The value
parameter is set to true
and the control is an ActiveX control.
GetTopLevel() の戻り値が、value
パラメーターと等しい値ではなく、Parent プロパティが null
ではありません。The GetTopLevel() return value is not equal to the value
parameter and the Parent property is not null
.
注釈
Form の SetTopLevel メソッドを呼び出し、false
の値を渡すと、もう一度 SetTopLevel を呼び出して true
の値を渡しても、フォームは表示されません。If you call the SetTopLevel method of a Form and pass in a value of false
, the form will not be visible until you call SetTopLevel again, passing in a value of true
.
セキュリティ
UIPermission
コントロールをトップレベルコントロールとして設定する場合は Form 以外の型の場合は。to set the control as a top-level control if it is of any type other than Form. このアクセス許可は、value
パラメーターが true
、コントロールが ActiveX コントロールではない場合にのみ要求されます。This permission is only demanded if the value
parameter is true
and the control is not an ActiveX control. 列挙型に関連付けられている: AllWindows
UIPermissionWindowします。Associated enumeration: AllWindows
value of UIPermissionWindow.