共用方式為


ParentControlDesigner.GetParentForComponent(IComponent) 方法

定義

衍生類別會在加入元件時,據以判斷是否傳回正在設計的控制項,或是其他的 Container

protected:
 virtual System::Windows::Forms::Control ^ GetParentForComponent(System::ComponentModel::IComponent ^ component);
protected virtual System.Windows.Forms.Control GetParentForComponent (System.ComponentModel.IComponent component);
abstract member GetParentForComponent : System.ComponentModel.IComponent -> System.Windows.Forms.Control
override this.GetParentForComponent : System.ComponentModel.IComponent -> System.Windows.Forms.Control
Protected Overridable Function GetParentForComponent (component As IComponent) As Control

參數

component
IComponent

要擷取其父代 Control 的元件。

傳回

元件的父代 Control

適用於

另請參閱