This is a migrated thread and some comments may be shown as answers.

Each Line of report on separate page?

1 Answer 84 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
John Hughes
Top achievements
Rank 1
John Hughes asked on 17 Dec 2010, 12:01 AM
I created a simple report that has some hard coded text in the header and has 3 fields in the detail area.  When I run the report in my application bound to a list of objects (with exposed properties), I get all items in the list list.  However, each line of the report comes out on a separate page.  My report design looks something like


(Header section)

                                        Activity Report

Project Name                     Task Name                       Cost
----------------------------------------------------------------------------


(Detail section)
[=Fields.ProjectName]         [=Fields.TaskName]          [=Fields.Cost]







As I mentioned, I have set the data source for the report to a List which right now
has 29 elements in it.  I expected multiple lines in the report with only 1 or 2 pages, but I end up with 29
pages!   Can anyone tell me what I did wrong?

It's probably something really basic, but this is the first time I used the tool, so bear with me.

Thanks,

John

1 Answer, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 20 Dec 2010, 06:04 PM
Hello John Hughes,

There are several cases when such a problem can occur:

  • Report Width is greater than than the available page space (Page Width - Left Margin - Right Margin).
  • There is a sub-report, which contains a report that is too wide, and while at design-time that is not obvious, at run-time it might cause the carry over to occur.
  • There is a report item (in your case HtmlTextBox) with boundaries going out to the right from its parent section.
Since often the background color (white in most cases) of the item that is carried over to the next page is the same as the background of the report/sections the page seems to be blank.
To see which items are causing the problem, simply change their background to a different, more contrasting color and run the report in the WinForms viewer or export it to PDF. The rendered report will immediately give you a clue about the items which are at fault. Then simply try making the report items smaller until the "blank" pages disappear or decrease the report width. We would advise creating the items so that they do not touch other items, section ends, etc., because the processing engine might produce unexpected results. Always leave a little space (a couple of pixels/points) around report items to prevent unexpected behavior.

In this line of thoughts if you still experience any troubles, we will highly appreciate if you prepare and send us a sample runnable project that demonstrates the unexpected behavior to debug locally.

Best wishes,
Peter
the Telerik team
Get started with Telerik Reporting with numerous videos and detailed documentation.
Tags
General Discussions
Asked by
John Hughes
Top achievements
Rank 1
Answers by
Peter
Telerik team
Share this question
or