0
votes

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)

  1. aaa
  2. bbb
  3. 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

  1. ooo
  2. ppp
  3. qqq





Name: Bob


  1. rrr
  2. sss
  3. ttt





Name: Bob


  1. uuu





The correct layout should be:


Name: Amy (here is main report)


page 1 of 2 (here is subreport)

  1. aaa
  2. bbb
  3. ccc





Name: Amy


page 2 of 2

  1. eee
  2. fff





Name: Bob


page 1 of 3

  1. ooo
  2. ppp
  3. qqq





Name: Bob


page 2 of 3

  1. rrr
  2. sss
  3. ttt





Name: Bob


page 3 of 3

  1. uuu

1

1 Answers

0
votes

Please try this, Open iReport tools->Edit menu->Report Properties->More...

you can see have a header in new page. have a footer in new page.

I use chinese language, Maybe translation have some little not precise. Just for your information