Visual Basic Reference

Visual Studio 6.0

ForcePageBreak Property

See Also    Example    Applies To

Returns or sets a value that determines how a page break will occur.

Syntax

object.ForcePageBreak [=integer]

The ForcePageBreak property syntax has these parts:

Part Description
object Required. An object expression that evaluates to an object in the Applies To list.
integer Optional. A numeric expression that specifies how the page break occurs, as shown in Settings.

Settings

The settings for integer are:

Constant Value Description
rptPageBreakNone 0 (Default) No page breaks occur.
rptPageBreakBefore 1 The page break occurs before the current section.
rptPageBreakAfter 2 The page break occurs after the current section.
rptPageBreakBeforeAndAfter 3 Page breaks occur both before and after the current section.

Remarks

Page breaks do not occur on every section consistently. The table below shows exceptions, according to sections.

Section Ignores
Report Header rptPageBreakBefore
Page Header rptPageBreakBefore

rptPageBreakAfter

rptPageBreakBeforeAndAfter

Page Footer rptPageBreakBefore

rptPageBreakAfter

rptPageBreakBeforeAndAfter


Show: