Hide Method

Applies To

DialogSheet Object.

Description

Hides a dialog box. If the dialog box is not currently displayed, an error occurs.

Syntax

object.Hide(cancel)

object

Required. The DialogSheet object.

cancel

Optional. If True, the dialog box is canceled without validating edit-box contents. If False or omitted, edit box contents are validated before returning. No macros assigned to Cancel or OK buttons are run in either case.

Remarks

If cancel is False and edit fields in the dialog box could not be validated then this method returns False, and the dialog box does not exit. Otherwise, this method returns True.

Example

This example hides the active dialog box.


ActiveDialog.Hide