Displaying Office-Standard Dialog Boxes

Word and Excel let you display, alter, and retrieve data from any of their built-in dialog boxes. (There is no comparable capability in Outlook, PowerPoint, FrontPage, or Access.) These techniques can come in handy if you just want to tweak a built-in dialog box and you don't want to go through the considerable hassle of trying to completely re-create the dialog box.

Using Built-In Excel Dialog Boxes with VBA

Say you want to write a VBA/Excel macro that displays the Open dialog box, but instead of the default list of various Excel file types, you only want to look for Web pages (those with an .htm extension). Here's how:

  1. Start Excel and press Alt+F11 to bring up the VBA Editor.

  2. Navigate to a convenient module ...

Get Special Edition Using Microsoft® Office XP now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.