ApplicationContext.MainForm 屬性

定義

取得或設定要當做內容使用的 Form

public:
 property System::Windows::Forms::Form ^ MainForm { System::Windows::Forms::Form ^ get(); void set(System::Windows::Forms::Form ^ value); };
public System.Windows.Forms.Form MainForm { get; set; }
public System.Windows.Forms.Form? MainForm { get; set; }
member this.MainForm : System.Windows.Forms.Form with get, set
Public Property MainForm As Form

屬性值

Form

要當做內容使用的 Form

備註

這個屬性會決定此內容的主要 Form 。 這個屬性可以隨時變更。 如果未 OnMainFormClosed 覆寫,當參數關閉時 mainForm ,執行緒的訊息迴圈就會終止。

適用於