NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Form.Owner

Gets or sets the form that owns this form.

[Visual Basic]
Public Property Owner As Form
[C#]
public Form Owner {get; set;}
[C++]
public: __property Form* get_Owner();
public: __property void set_Owner(Form*);
[JScript]
public function get Owner() : Form;
public function set Owner(Form);

Property Value

A Form that represents the form that is the owner of this form.

Remarks

To make a form owned by another form, assign its Owner property a reference to the form that will be the owner.

When a form is owned by another form, it is minimized and closed with the owner form. For example, if Form2 is owned by form Form1, if Form 1 is closed or minimized, Form2 is also closed or minimized. Owned forms are also never displayed behind their owner form. You can use owned forms for windows such as find and replace windows, which should not disappear when the owner form is selected.To determine the forms that are owned by a parent form, use the OwnedForms property.

See Also

Form Class | Form Members | System.WinForms Namespace