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

Dynamically set PageHeaderSection height

5 Answers 348 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Wayne
Top achievements
Rank 1
Wayne asked on 10 Jun 2012, 10:32 AM

Hi,

I have a standard report with: PageHeaderSection,  GroupHeaderSection -  DetailSection etc. My problem is the paper on which the report is being printed on, it may have a pre- printed Logo on the top. What I need is to dynamically set the page margin or better the PageHeaderSection height. But it seems this is not possible. Could you please give me a solution to this problem.

Thank you and Kind regards
Wayne

5 Answers, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 14 Jun 2012, 07:27 AM
Hello Wayne,

Generally speaking the paging is the process of fitting as many as possible report items into a page. In order to do this first we have to define the available space for the content (the report items) on the page. The available space is usually calculated from the page size minus the page margins and the page sections. So your assumption is correct, it is not possible to have a dynamically sized page section for different pages of a single report. If the size would be different for the whole report, then you can change it through the PageSettings API.


Kind regards,
Steve
the Telerik team

BLOGGERS WANTED! Write a review about Telerik Reporting or the new Report Designer, post it on your blog and get a complimentary license for Telerik Reporting. We’ll even promote your blog and help bring you a few fresh readers. Yes, it’s that simple. And it’s free. Get started today >

0
Michal
Top achievements
Rank 1
answered on 15 Jun 2012, 09:31 AM
Hi.
I think I have similar issue - I need to hide some parts of the header depending on page number - lets say: show image on first page, hide it in second, show in third etc.

After Your respond I assume that this is also not possible. Am I right or is there any way to achieve that?
0
Steve
Telerik team
answered on 15 Jun 2012, 10:22 AM
Hi Michal,

What you want is possible as you hide an item inside page section and do not change its size. You can use the built-in PageNumber and PageCount objects in a Bindings expression for the Visible property of that item e.g.:

Property Path                                              Expression
========================================================
Visible                                                  =IIF(PageNumber %2 = 0, true, false)

Kind regards,
Steve
the Telerik team

BLOGGERS WANTED! Write a review about Telerik Reporting or the new Report Designer, post it on your blog and get a complimentary license for Telerik Reporting. We’ll even promote your blog and help bring you a few fresh readers. Yes, it’s that simple. And it’s free. Get started today >

0
Einar Dahle
Top achievements
Rank 1
answered on 11 Oct 2013, 06:53 AM
then would it shrink back to fill the hidden space ?
0
Stef
Telerik team
answered on 11 Oct 2013, 02:00 PM
Hello Einar,

Setting the page sections Visible properties causes the sections to be displayed or not. The occupied space would not shrink as explained in the Report Structure and Understanding Rendering Behaviors help articles.

Regards,
Stef
Telerik

Have you tried the new visualization options in Telerik Reporting Q2 2013? You can get them from your account.

Tags
General Discussions
Asked by
Wayne
Top achievements
Rank 1
Answers by
Steve
Telerik team
Michal
Top achievements
Rank 1
Einar Dahle
Top achievements
Rank 1
Stef
Telerik team
Share this question
or