Page Event -- Event Procedures

Description

To create an event procedure that is executed when the Page event occurs, set the OnPage property to [Event Procedure], and click the Build button.

Syntax

Private Sub Report_Page( )

Remarks

You can’t cancel the Page event.

See Also

Page Event — Macros.

Example

The following example shows how to draw a rectangle around a report page, using the Line method. The ScaleWidth and ScaleHeight properties by default return the internal width and height of the report.


Private Sub Report_Page()
    Me.Line(0, 0)-(Me.ScaleWidth, Me.ScaleHeight), , BSub