Form.
You can use the ControlBox property to specify whether a form has a Control menu in Form view.
The ControlBox property uses the following settings.
Setting | Description | Visual Basic |
Yes | (Default) The form has a Control menu in Form view. | True (-1) |
No | The form doesnt have a Control menu in Form view. | False (0) |
You can set this property using the forms property sheet, a macro, or Visual Basic.
You can set this property only in form Design view.
Note Setting the ControlBox property to No removes the Minimize, Maximize, and Close buttons on a form.
To display a Control menu on a form, the ControlBox property must be Yes and the forms BorderStyle property must be set to Thin, Sizable, or Dialog.
Even when a forms ControlBox property is set to No, the form always has a Control menu when opened in Design view.
Setting the ControlBox property to No suppresses the Control menu when you open the form in Form view from the Database window, using a macro, or Visual Basic. The Control menu is also suppressed when you switch to another view from Form view.
BorderStyle Property, CloseButton Property, MinMaxButtons Property, Modal Property, PopUp Property.
The following example sets the ControlBox property on the WarningBox form to False.
Forms!WarningBox.ControlBox = False