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

Report Paging w/subreport Problem

5 Answers 315 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Bill Hicks
Top achievements
Rank 1
Bill Hicks asked on 21 Jan 2011, 11:28 AM
I have one master report with 12 sub-reports in it.  When I run the report which is 8.5 x 11 letter paper the report shows as one huge page.  I just need to find out how to page properly between letter-sized pages.  I'm not too concerned where the pages break within the sub-reports but I would like to keep certain sub-report detail t

5 Answers, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 21 Jan 2011, 05:11 PM
Hi Bill,

I assume you're using the Web Report Viewer which uses the HTML rendering, thus creating logical pages.
The output of a report rendered in HTML and page oriented e.g. PDF differs because both medias are quite different. The 1st (HTML) is dedicated to displaying information on screen and the page is infinite by width and height; in contrast the 2nd format - PDF - supports physical pages and is meant not only for reading on screen but for printing.

According to whether the format supports physical pages, we separate the export formats on two groups: page-oriented (PDF, Image (print preview), print, XPS, RTF) and non-page oriented (HTML/MHTML, Excel, CSV).

For the page-oriented formats the content layout is on horizontal and vertical pages according the the page settings of the report, while for the rest of the formats take into considerations other characteristics of the media like the grid of the Excel worksheet.

In short, the only way to force the subreports to be placed on different pages is to create 12 unbound groups and place each subreport in a separate groupheader or groupfooter with PageBreak property After or Before depending on whether you're using header or footer.

Kind regards,
Steve
the Telerik team
Get started with Telerik Reporting with numerous videos and detailed documentation.
0
Bill Hicks
Top achievements
Rank 1
answered on 26 Jan 2011, 04:39 AM
Thanks for the reply Steve.  I am using the report viewer for HTML output.  When I create a report with header/detail/footer, and specify the height in the report or paper size, for example "Letter" format, the report does indeed output and page break in 8 & 1/2 size pages.  So a report that would print out on say 5 sheets of letter paper actually breaks in the HTML viewer on 5 separate pages.   I'm not concerned with PDF output at this point.  My question is why would putting sub-reports into the detail section of the report not follow my overall page size settings?  Shouldn't the report still break at letter sizes as I've specified?  It makes no sense to have a massively long report created from the combination of reports, unless i use something like the "Report Book" format.   I will try the grouping suggestion but this seems like a slightly less-elegant solution.
0
Steve
Telerik team
answered on 26 Jan 2011, 03:02 PM
Hello Bill,

I've already explained the reason for this behavior - the fact that HTML is not page oriented format and thus the page settings mean nothing to it. Think of the HTML format as "Interactive" layout of the report, while page oriented formats like PDF are the "Print" layouts.

Best wishes,
Steve
the Telerik team
Get started with Telerik Reporting with numerous videos and detailed documentation.
0
Bill Hicks
Top achievements
Rank 1
answered on 11 Feb 2011, 05:54 AM

This seems to be from a previous poster that replied to this thread that was deleted:   "This is a serious draw back for me. I am replaceing Actuate Reporting with Telerik and I need to have the paging of Sub reports. Also when it pagenates in the PDF output I do not get a header for the sub reports. I would hate to have to withdraw my recommendation to go with Telerik tools because I can not create the format that is expected from my web/pdf reports."

I understand your explanation but the fact remains, my report behaves properly when rendered with the HTML control (pages are broken @ 11in) until I add sub-reports.  Why don't sub-reports get rendered along with the rest of the report in the proper page size?   You say "the fact that HTML is not page oriented format and thus the page settings mean nothing to it.".  If this is the case, then why does my normal header/detail/footer report get formatted properly in HTML?  Wouldn't it also end up being 1 long report when output via HTML?  What's the point of paging controls if this cannot be accomplished?

0
Steve
Telerik team
answered on 14 Feb 2011, 08:22 AM
Hello Bill,

Threads in our system are not deleted under any circumstances, especially when coming from users with valid accounts. If a post contains adds or offensive language it can be edited to remove that content or migrated to our support system so we can warn the user, but never completely deleted, unless the user has been warned and he continues to be vocal in our forums. This is not the case with this particular thread and after advising with our web team, it seems that this could be due to a continuous migration they're doing for all of our sites.
Up to your and the other user's concerns:
  • I need to have the paging of Sub reports - they are paged even now for page oriented formats. This does not apply for SubReports in non page oriented formats as HTML only and is by design. See previous replies in this thread for more information. Also this is duly noted in our documentation: Design Considerations for HTML Rendering.
  • I do not get a header for the sub reports - page sections (page header and page footer) are not related to the report itself, but are relative to the margins of the report's media, i.e. to the paper or screen. In short they precede all report sections and there can only be one page header/footer. On the other hand, SubReports are nested in report section as part of the main report which already has page sections. This info is also duly noted in our documentation: SubReport. In that article we suggest a workaround by using unbound group headers.
  • report behaves properly when rendered with the HTML control until I add sub-reports - non page oriented formats have logical paging based on the report rules and not based on the page settings. In this line of thoughts, any item that grows to normally accommodate more than a single page, would be rendered as a single page in HTML. You do not have other items that exhibit this in your report and that is why the SubReport item seems like renegade to you. Try placing a TextBox with very large text that would surely surpass single page according to report page settings and you would observe exactly the same behavior. This information is present in the Design Considerations for HTML Rendering.
@Bill: except the grouping solution I've suggested in first post, the Report Book feature might be just the thing for your case. Instead of using SubReport item to render reports into main report, you combine those reports into a Report Book. As seen from the documentation, each report in a book would be rendered on a separate page from the other ones and can have its own paging or combined paging for the whole report book (whichever you need).

Hope this clears any further confusion on the matter.

Regards,
Steve
the Telerik team
Get started with Telerik Reporting with numerous videos and detailed documentation.
Tags
General Discussions
Asked by
Bill Hicks
Top achievements
Rank 1
Answers by
Steve
Telerik team
Bill Hicks
Top achievements
Rank 1
Share this question
or