I am using iReport 4.0.2 to create a Main Report which contains one subreport. I try to add some static text in the Page-Header-Band and Page-Footer-Band of the subreport and I expect that the text in Page-Header-Band and Page-Footer-Band will be repeated, but these text are only shown in the first page of the subreport (but not on the rest of the pages) if the subreport itself has multiple page.
Actually what I want to do is to put a "Page x of n" variable in the subreport so the subreport can has its own set of page number.
This is the layout of my current report: (sorry I hv no permission uploading image here)
Name: Amy (here is main report)
page 1 of 2 (here is subreport)
- aaa
- bbb
- ccc
Name: Amy
<--- Page number missing (in fact, the entire Page-Header-Band disappear! That is, Page-Header-Band is not repeated on every page of the subreport)
1. eee
2. fff
Name: Bob
page 1 of 3
- ooo
- ppp
- qqq
Name: Bob
- rrr
- sss
- ttt
Name: Bob
- uuu
The correct layout should be:
Name: Amy (here is main report)
page 1 of 2 (here is subreport)
- aaa
- bbb
- ccc
Name: Amy
page 2 of 2
- eee
- fff
Name: Bob
page 1 of 3
- ooo
- ppp
- qqq
Name: Bob
page 2 of 3
- rrr
- sss
- ttt
Name: Bob
page 3 of 3
- uuu