Home » Archived » BIRT » Master page header and footer content visibility
| Master page header and footer content visibility [message #368203] |
Tue, 12 May 2009 06:06  |
Eclipse User |
|
|
|
Hello,
we have simple report with content in simple master page's header and
footer. We need to show that content only on first page of report. On the
following pages it should be hidden.
I haven't found any way to do it. Is there a way how this can be
accomplished?
Thanks
Ludevik
|
|
| |
| Re: Master page header and footer content visibility [message #368277 is a reply to message #368213] |
Mon, 18 May 2009 04:46   |
Eclipse User |
|
|
|
Jason,
the problem is that we dont have only one big table in report. We have
multiple text items followed by two tables and after them some more text
items. It is a company letter - using header and footer, at the top is
address, then some texting followed by tables, and signature at the end.
The client wants to have company letter header and footer only on first
page.
Tables have page break interval set to 40. Usually the tables contains
only few rows, but still some items are on the second page. These tables
could also contain more rows, so we dont know how set the page break
interval, because the first 3 rows could fit into first page, and other
100 should break on following pages.
Ludovit
Jason Weathersby wrote:
> Ludovit,
> One way to do this is on the onrender event for the element in the
> footer check the pagenumber. For example say you have a text element in
> the footer:
> if( pageNumber > 1 ){
> this.text = "";
> }
> Keep in mind that the pageNumber variable is the html page number, so
> set your page break interval to something that will make it smaller than
> your pdf output page.
> Jason
> Ludovit Hajzer wrote:
>> Hello,
>>
>> we have simple report with content in simple master page's header and
>> footer. We need to show that content only on first page of report. On
>> the following pages it should be hidden.
>> I haven't found any way to do it. Is there a way how this can be
>> accomplished?
>>
>> Thanks
>>
>> Ludevik
>>
|
|
|
| Re: Master page header and footer content visibility [message #368282 is a reply to message #368277] |
Mon, 18 May 2009 11:47   |
Eclipse User |
|
|
|
Originally posted by: jasonweathersby.alltel.net
Ludovit,
Do you have any idea what items will be processed for the first page?
If you do you can always write a page break into a row of a table.
I have done this in the past based on a column value for example:
//oncreate for table row
var rowcount = this.getRowData().getColumnValue("rwc");
if( rowcount%15 == 0 ){
this.getStyle().pageBreakAfter = "Always";
}
Jason
Ludovit Hajzer wrote:
> Jason,
> the problem is that we dont have only one big table in report. We have
> multiple text items followed by two tables and after them some more text
> items. It is a company letter - using header and footer, at the top is
> address, then some texting followed by tables, and signature at the end.
> The client wants to have company letter header and footer only on first
> page.
>
> Tables have page break interval set to 40. Usually the tables contains
> only few rows, but still some items are on the second page. These tables
> could also contain more rows, so we dont know how set the page break
> interval, because the first 3 rows could fit into first page, and other
> 100 should break on following pages.
>
> Ludovit
>
> Jason Weathersby wrote:
>
>> Ludovit,
>
>> One way to do this is on the onrender event for the element in the
>> footer check the pagenumber. For example say you have a text element
>> in the footer:
>
>> if( pageNumber > 1 ){
>> this.text = "";
>> }
>
>> Keep in mind that the pageNumber variable is the html page number, so
>> set your page break interval to something that will make it smaller
>> than your pdf output page.
>
>> Jason
>
>> Ludovit Hajzer wrote:
>>> Hello,
>>>
>>> we have simple report with content in simple master page's header and
>>> footer. We need to show that content only on first page of report. On
>>> the following pages it should be hidden.
>>> I haven't found any way to do it. Is there a way how this can be
>>> accomplished?
>>>
>>> Thanks
>>>
>>> Ludevik
>>>
>
>
|
|
|
| Re: Master page header and footer content visibility [message #368366 is a reply to message #368282] |
Tue, 26 May 2009 09:11   |
Eclipse User |
|
|
|
Jason,
we finally made what we needed based on your proposal. Unfortunately this
is working only for PDF format, as there is problem with headers and
footers in DOC format. I don't know if it is possible to generate
different headers/footers also for Doc format through BIRT.
In office 2003 there's option to set different header/footer for first
page, and different for the rest of document, this would be nice if it
were implemented also in BIRT.
Ludovit
Jason Weathersby wrote:
> Ludovit,
> Do you have any idea what items will be processed for the first page?
> If you do you can always write a page break into a row of a table.
> I have done this in the past based on a column value for example:
> //oncreate for table row
> var rowcount = this.getRowData().getColumnValue("rwc");
> if( rowcount%15 == 0 ){
> this.getStyle().pageBreakAfter = "Always";
> }
> Jason
> Ludovit Hajzer wrote:
>> Jason,
>> the problem is that we dont have only one big table in report. We have
>> multiple text items followed by two tables and after them some more text
>> items. It is a company letter - using header and footer, at the top is
>> address, then some texting followed by tables, and signature at the end.
>> The client wants to have company letter header and footer only on first
>> page.
>>
>> Tables have page break interval set to 40. Usually the tables contains
>> only few rows, but still some items are on the second page. These tables
>> could also contain more rows, so we dont know how set the page break
>> interval, because the first 3 rows could fit into first page, and other
>> 100 should break on following pages.
>>
>> Ludovit
>>
>> Jason Weathersby wrote:
>>
>>> Ludovit,
>>
>>> One way to do this is on the onrender event for the element in the
>>> footer check the pagenumber. For example say you have a text element
>>> in the footer:
>>
>>> if( pageNumber > 1 ){
>>> this.text = "";
>>> }
>>
>>> Keep in mind that the pageNumber variable is the html page number, so
>>> set your page break interval to something that will make it smaller
>>> than your pdf output page.
>>
>>> Jason
>>
>>> Ludovit Hajzer wrote:
>>>> Hello,
>>>>
>>>> we have simple report with content in simple master page's header and
>>>> footer. We need to show that content only on first page of report. On
>>>> the following pages it should be hidden.
>>>> I haven't found any way to do it. Is there a way how this can be
>>>> accomplished?
>>>>
>>>> Thanks
>>>>
>>>> Ludevik
>>>>
>>
>>
|
|
|
| Re: Master page header and footer content visibility [message #368368 is a reply to message #368366] |
Tue, 26 May 2009 10:32  |
Eclipse User |
|
|
|
Originally posted by: jasonweathersby.windstream.net
Have you logged a bug for this?
Also you can have different master pages and set the one you want based
on the output format, but this method only works if regenerate the
report for the specific format. Ie it does not work exporting the same
rptdocument to different formats. The rptdocument has to be recreated.
Jason
Ludovit Hajzer wrote:
> Jason,
>
> we finally made what we needed based on your proposal. Unfortunately
> this is working only for PDF format, as there is problem with headers
> and footers in DOC format. I don't know if it is possible to generate
> different headers/footers also for Doc format through BIRT.
> In office 2003 there's option to set different header/footer for first
> page, and different for the rest of document, this would be nice if it
> were implemented also in BIRT.
>
> Ludovit
>
> Jason Weathersby wrote:
>
>> Ludovit,
>
>> Do you have any idea what items will be processed for the first page?
>> If you do you can always write a page break into a row of a table.
>
>> I have done this in the past based on a column value for example:
>
>> //oncreate for table row
>> var rowcount = this.getRowData().getColumnValue("rwc");
>
>> if( rowcount%15 == 0 ){
>> this.getStyle().pageBreakAfter = "Always";
>> }
>
>
>> Jason
>
>> Ludovit Hajzer wrote:
>>> Jason,
>>> the problem is that we dont have only one big table in report. We
>>> have multiple text items followed by two tables and after them some
>>> more text items. It is a company letter - using header and footer, at
>>> the top is address, then some texting followed by tables, and
>>> signature at the end. The client wants to have company letter header
>>> and footer only on first page.
>>>
>>> Tables have page break interval set to 40. Usually the tables
>>> contains only few rows, but still some items are on the second page.
>>> These tables could also contain more rows, so we dont know how set
>>> the page break interval, because the first 3 rows could fit into
>>> first page, and other 100 should break on following pages.
>>>
>>> Ludovit
>>>
>>> Jason Weathersby wrote:
>>>
>>>> Ludovit,
>>>
>>>> One way to do this is on the onrender event for the element in the
>>>> footer check the pagenumber. For example say you have a text
>>>> element in the footer:
>>>
>>>> if( pageNumber > 1 ){
>>>> this.text = "";
>>>> }
>>>
>>>> Keep in mind that the pageNumber variable is the html page number,
>>>> so set your page break interval to something that will make it
>>>> smaller than your pdf output page.
>>>
>>>> Jason
>>>
>>>> Ludovit Hajzer wrote:
>>>>> Hello,
>>>>>
>>>>> we have simple report with content in simple master page's header
>>>>> and footer. We need to show that content only on first page of
>>>>> report. On the following pages it should be hidden.
>>>>> I haven't found any way to do it. Is there a way how this can be
>>>>> accomplished?
>>>>>
>>>>> Thanks
>>>>>
>>>>> Ludevik
>>>>>
>>>
>>>
>
>
|
|
|
Goto Forum:
Current Time: Sun Nov 09 01:28:50 EST 2025
Powered by FUDForum. Page generated in 0.07084 seconds
|