Microsoft Word Suite
339
Command: show
Displays and carries out actions initiated in the specified built-in Word dialog box. Returns an
integer that indicates which button was clicked to close the dialog box.
Return value
Description
-2 The
Close button.
-1 The
OK button.
0 (zero)
The Cancel button.
> 0 (zero)
A command button: 1 is the first button, 2 is the second button, and so on.
Note To display a dialog box but not have any actions carried out or settings applied when the
dialog box is closed, use the
display Word dialog
command.
Syntax
show dialog Required. An expression that returns a dialog object.
[time out integer] Optional. The amount of time that Word will wait before closing the dialog
box automatically. One unit is approximately 0.001 second. Concurrent system activity may
increase the effective time value. If this argument is omitted, the dialog box is closed when the
user dismisses it.
Example
This example displays and carries out any action initiated in the Zoom dialog box. If there are no
actions initiated for approximately 9 seconds, the dialog box is closed.
show (get dialog dialog view zoom) time out 9000
Command: show all headings
Toggles between showing all text (headings and body text) and showing only headings.
Note This method generates an error if the view isnt outline view or master document view.
Syntax
show all headings view Required. An expression that returns a view object.
Example
This example uses the show heading command to show all headings (without any body text) and
then toggles the display to show all text (headings and body text) in outline view.
set view type of view of active window to outline view
show heading view of active window level 9
show all headings view of active window