ActiveReports 8 > ActiveReports User Guide > Samples and Walkthroughs > Walkthroughs > Page Report Walkthroughs > Layout > Overflow Data in Multiple Pages |
In a fixed page layout you can create different layouts in a single report by designing your report on more than one page tab. This walkthrough describes the steps to create two different layouts and how data flows from the first layout to the next using the OverflowPlaceHolder control.
This walkthrough is split into the following activities:
Note: This walkthrough uses the CustomerOrders table from the Reels database. By default, in ActiveReports, the Reels.mdb file is located at [User Documents folder]\ComponentOne Samples\ActiveReports 8\Data\Reels.mdb. |
When you complete this walkthrough you get a layout that looks similar to the following at design time and at run time.
Page 1 | Page 2 | ||
---|---|---|---|
|
|
Notice that the runtime report layout below is similar to the one you see at design time except for the data which is added to the report at runtime or when you preview it.
Page 1 | Page 2 | ||
---|---|---|---|
|
|
To add an ActiveReport to the Visual Studio project
See Adding an ActiveReport to a Project for information on adding different report layouts.
To connect the report to a data source
To add a dataset
SQL Query |
Copy Code
|
---|---|
Select * from customerorders
|
To create a layout for the first page
=Fields!SalesID.Value.
See Grouping in a FixedPage to understand grouping further.Controls
Control | Properties | ||
---|---|---|---|
Textbox | Color: DarkSlateBlue Font: Normal, Arial, 11pt, Bold Location: 0in, 1in Size: 2in, 0.25in TextAlign: Center Value: 5473 Sidelong Street |
||
Textbox | Color: DarkSlateBlue Font: Normal, Arial, 11pt, Bold Location: 0in, 1.25in Size: 2in, 0.25in TextAlign: Center Value: Siler City, NC. 27344 |
||
Textbox | Font: Normal, Arial, 10pt, SemiBold Location: 0in, 2in Size: 1in, 0.25in TextAlign: Right Value: Sales Date : |
||
Textbox | Font: Normal, Arial, 10pt, SemiBold Location: 0in, 2.25in Size: 1in, 0.25in TextAlign: Right Value: Sales ID : |
||
Textbox | Font: Normal, Arial, 10pt, SemiBold Location: 3in, 2in Size: 1.5in, 0.25in TextAlign: Right Value: Customer Name : |
||
Textbox | Font: Normal, Arial, 10pt, SemiBold Location: 3in, 2.25in Size: 1.5in, 0.25in TextAlign: Right Value: Address : |
||
Textbox | Font: Normal, Arial, 10pt, SemiBold Location: 3in, 2.50in Size: 1.5in, 0.25in TextAlign: Right Value: City : |
||
Textbox | Font: Normal, Arial, 10pt, SemiBold Location: 3in, 2.75in Size: 1.5in, 0.25in TextAlign: Right Value: Country : |
||
Textbox | Font: Normal, Arial, 10pt, SemiBold Location: 0in, 4in Size: 1.5in, 0.25in TextAlign: Right Value: Account Number: |
||
Table |
BorderStyle: Solid FixedSize: 6.5in, 2in Location: 0in, 5in OverflowName: OverflowPlaceHolder1
Size: 6.5in, 0.75in |
Fields
Field | Properties |
---|---|
SaleDate | Format: D Location: 1in, 2in Size: 2in, 0.25in TextAlign: Left |
SalesID | Location: 1in, 2.25in Size: 2in, 0.25in TextAlign: Left |
FirstName | Location: 4.5in, 2in Size: 2in, 0.25in TextAlign: Left |
Address1 | Location: 4.5in, 2.25in Size: 2in, 0.25in TextAlign: Left |
City | Location: 4.5in, 2.5in Size: 2in, 0.25in TextAlign: Left |
Country | Location: 4.5in, 2.75in Size: 2in, 0.25in TextAlign: Left |
AccountNumber | Location: 1.5in, 4in Size: 2in, 0.25in TextAlign: Left |
Cell | Field | Properties |
---|---|---|
Left Cell | Title | BorderStyle: Solid TextAlign: Center |
Middle Cell | Quantity | BorderStyle: Solid TextAlign: Center |
Right Cell | Price | BorderStyle: Solid Format: c TextAlign: Center |
This automatically places an expression in the details row and simultaneously places a static label in the header row of the same column.
Property Name | Value |
---|---|
BackgroundColor | Silver |
Font | Normal, Arial, 11pt, Bold |
RepeatOnNewPage | True |
TextAlign | Center |
Cell | Properties |
---|---|
Middle Cell | Font: Normal, Arial, 10pt, Bold TextAlign: Right Value: Total: |
Right Cell | Font: Normal, Arial, 10pt, Bold Format: c TextAlign: Center Value: =Sum(Fields!Price.Value) |
To create a layout for subsequent Pages
Controls
Control | Properties |
---|---|
Textbox | Font: Normal, Arial, 12pt, Bold Location: 0in, 1in Size: 2.625in, 0.25in TextAlign: Right Value: Account Details: |
Textbox | Font: Normal, Arial, 12pt, Bold Location: 2.625in, 1in Size: 3.25in, 0.25in Value: =Fields!FirstName.Value + ", " + Fields!AccountNumber.Value |
OverflowPlaceHolder | Location: 0in, 2in |
Textbox | Location: 1.75in, 5in Size: 3in, 0.25in TextAlign: Center Value: Thank You For Your Business! |
To view the report
OR