System.Windows.Forms.Form.MaximizeBox Property

Gets or sets a value indicating whether the Maximize button is displayed in the caption bar of the form.

Syntax

[System.ComponentModel.DefaultValue(true)]
public bool MaximizeBox { set; get; }

Value

Documentation for this section has not yet been entered.

Remarks

A Maximize button enables users to enlarge a window to full-screen size. To display a Maximize button, you must also set the form's Form.FormBorderStyle property to FormBorderStyle.FixedSingle, FormBorderStyle.Sizable, FormBorderStyle.Fixed3D, or FormBorderStyle.FixedDialog.

A Maximize button automatically becomes a restore button when a window is maximized. Minimizing or restoring a window automatically changes the restore button back to a Maximize button.

Note:

Maximizing a form at run time generates a Control.Resize event. The Form.WindowState property reflects the current state of the window. If you set the Form.WindowState property to FormWindowState.Maximized, the form is maximized independently of whatever settings are in effect for the Form.MaximizeBox and Form.FormBorderStyle properties.

Requirements

Namespace: System.Windows.Forms
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0