Dialog object (Word)

Represents a built-in dialog box. The Dialog object is a member of the Dialogs collection. The Dialogs collection contains all the built-in dialog boxes in Word. You cannot create a new built-in dialog box or add one to the Dialogs collection.

Remarks

Use Dialogs (Index), where Index is a WdWordDialog constant that identifies the dialog box, to return a single Dialog object. The following example displays and carries out the actions taken in the built-in Open dialog box.

dlgAnswer = Dialogs(wdDialogFileOpen).Show

The WdWordDialog constants are formed from the prefix "wdDialog" followed by the name of the menu and the dialog box. For example, the constant for the Page Setup dialog box is wdDialogFilePageSetup, and the constant for the New dialog box is wdDialogFileNew.

For more information about working with built-in Word dialog boxes, see Displaying built-in Word dialog boxes.

See also

Word Object Model Reference

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.