ActiveReports 11
Add Page Counters
ActiveReports 11 > ActiveReports User Guide > How To > Page Report/RDL Report How To > Add Page Counters

The sum of values in each page for a text box in a data region can be obtained by using ReportItems. The ReportItems adds the values in the whole page regardless of scope while the Sum function adds the values for each group by specifying the scope (that is group name) as the second argument.

To obtain sum of TextBox1 that is part of a List or a Table data region for each page, in another text box (TextBox2), set the Value property of TextBox2 to the following expression:

=Sum(ReportItems!TextBox1.Value)

For example, to add a page counter using ReportItems for a Table data region

  1. Select the text box (TextBox6) in the Table data region for which you want to obtain the sum.
  2. Drag and drop a text box below the table (TextBox10). This text box will display the sum of the value contained in TextBox1 on each page.
  3. Enter the following expression in the value property of TextBox10:

    =Sum(ReportItems!TextBox6.Value)

  4. Go to Preview tab to view the result.