DisplayPageBoundaries Property

Microsoft Word Visual Basic

DisplayPageBoundaries Property

       

True to display the top and bottom margins (white space) and the gray area (gray space) between pages in a document. False to hide from view the white and gray space so that the pages flow together as one long page. The default value is True. Read/write Boolean.

expression.DisplayPageBoundaries

expression   Required. An expression that returns a View object.

Remarks

This feature is only available in the Print Layout view and only affects the gray space on the top and bottom of a page, not the left and right sides of a page.  This setting affects the document in the in the specified window. When the document is saved, the state of this setting is saved with it.

Example

This example changes the current view to Print Layout and suppresses the white and gray space between document pages.

Sub WhiteSpace()
    With ActiveWindow.View
        .Type = wdPrintView
        .DisplayPageBoundaries = False
    End With
End Sub