Gets or sets the MainMenu that is displayed in the form.
[Visual Basic] Public Property Menu As MainMenu [C#] public MainMenu Menu {get; set;} [C++] public: __property MainMenu* get_Menu(); public: __property void set_Menu(MainMenu*); [JScript] public function get Menu() : MainMenu; public function set Menu(MainMenu);
A MainMenu that represents the menu to display in the form.
You can use this property to switch between complete menu sets at run time. For example, you can define one MainMenu to be displayed when your multiple document interface (MDI) form has no active MDI child forms and another MainMenu to display when a child window is displayed. You can also use a different MainMenu when specific conditions exist in your application that requires displaying a different menu set.
Form Class | Form Members | System.WinForms Namespace | MainMenu | MenuItem | Menu