Gets or sets the maximum number of pages allowed for a report.

Namespace:  C1.C1Report
Assembly:  C1.C1Report.2 (in C1.C1Report.2.dll)

Syntax

Remarks

This property is useful if you want to limit the maximum number of pages in a report.

For example, you may write a report designer with a preview window that shows only the first five pages of a report.

Setting this property to zero allows reports of any length.

You can also limit the size of reports by setting the MaxRecords property.

The default value for this property is 0.

Examples

The following code uses the MaxPages property to limit the maximum number of pages in a report to the first five pages:

Copy CodeVisual Basic
Private Sub c1r_StartPage(ByVal sender As System.Object, ByVal e As C1.C1Report.ReportEventArgs) Handles c1r.StartPage
    Me.c1r.MaxPages = 5
End Sub
Copy CodeC#
private void c1r_StartPage(object sender, C1.C1Report.ReportEventArgs e)
{
    this.c1r.MaxPages = 5;
}

See Also