PDA

View Full Version : Group Footer's header



Anonymous
09-16-2002, 10:39 PM
Urrr Right now I'm using jFreeReport it work really great for me but when i try to make some more complex report, i can't do it..
the problem is.....
I want to group one column at the end of report. I want it to be my footer's header, is it possible? Ok i will show you my expect

FirstName LastName StudyRoom Score
AAAA AA c1 5
BBBB BB c1 10
CCCC CC b1 1
DDDD DD b1 1
EEEE EE c1 5
FFFF FF b1 2
Total : 24
Room Count Total Score
c1 3 20
b1 3 4

errr Somethigns like this.. Could it possible to make report look like this? can you show some xml? errr i didn't use cvs at all

Keep Going
Thank in advance
Jeng....

Anonymous
09-17-2002, 03:41 PM
Hi,

currently there is no solution for this problem, except the "solution" to use 2 reports instead (same grouping, no itemband) for the footer summary.
Making this posible is the current task, all done with the upcomming layouting changes ...

Have more fun,
said Thomas

Anonymous
09-17-2002, 09:55 PM
Ahh thank you.... but is it possible to make the hidden rows is invisible.. Errrr, i mean when i try to make group header it will leave the duplicate row blank (hide) like.. if i try to make a group by "Study Room" it will leave
2 blanks line before print the next group head...

b1
<---- I don't want this blank
<---- I don't want this blank
c1
<---- I don't want this blank
<---- I don't want this blank

or this is the same case as above???

Thank anyway
Keep Going,
said Jeng (aahh i didn't copy you by intention :P )

Anonymous
09-18-2002, 03:49 PM
Hi,

try to set the band invisible instead all elements. Invisible elements are not printed but the band does consume the defined height as long as the band is visible. Invisible bands do no consume any height, so you don't get any blank lines.

Have more fun,
said Thomas

Anonymous
09-21-2002, 01:03 AM
Hi,

I'm so sorry to say that I don't understand what you mean.. :( i'm really new for JfreeReport. Would you mind to show me how to do it? Please... I didn't use CVS at all..

Thank in advance
Keep going
Jeng

Anonymous
09-21-2002, 05:39 AM
Hi,

it's simple and no magic involved ...
For the second report (where the bands should be hidden), you have to hide the ItemBand (and with that also all fields defined in the <items> tag in the report) by calling

report.getItemBand().setVisible (false);

after the report has been generated.

To hide a group header, call

report.getGroup("groupName").getGroupHeader().setVisible(false);

and for the footer

report.getGroup("groupName").getGroupFooter().setVisible(false);
.

The ReportHeader is reachable via report.getReportHeader(), similiar applies for the footer: report.getReportFooter();
Both are bands and can be hidden the same way.

Have more fun,
said Thomas

Anonymous
09-22-2002, 11:37 PM
Hi,

Thank you very much for your help but i still have some curiouses...
According from your solutions, there are no way to set hidden band in the xml file? The only way to solve this is to set it in coding?

Ummm Thank you. I really fun with this program :)
Jeng,

Anonymous
09-23-2002, 02:37 PM
Hi,

yes, you have to set it in code, the parser does not understand the visible attribute...

Have more fun,
said Thomas