Jump to content
We've recently updated our Privacy Statement, available here ×

It is possible to Indent the group headers?


jensen_lien

Recommended Posts

 I have a problem when using ireport; I need to design a report like this:



Level


First Name


Last Name


Age




1


Jensen


L


30


 


 



Level


First Name


Last Name


Age




 



2


Jim


Z


30




 



Level


First Name


Last Name


Age


 


 



3


Jack


W


30


 

                             

                     ……


                                   ……

For different level there will be a group header for it and the header needs to be indented based on the level value. I want to know if it is possible to indent the headers with ireport.

Any body can help me...Thanks.
Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

please try:

-  Create on detail band one subreport selecting FistName, Lastname ect.

          query :  select * from  (yourFile)  where yourFile.Level = $P{P_LEVEL}

-  Assign subreport param : P_LEVEL     type :  what it is ?

-  Copy 3 times the created subreport on detail band as follow

                 |_____________________|    printWithExpression : new Boolean($F{Level}.intValue() = 1)

                               |______________________|    printWithExpression : new Boolean($F{Level}.intValue() = 2)

                                                 |_______________________|   printWithExpression : new Boolean($F{Level}.intValue() = 3)

               for each subreport   in properties :  Remove line when blank  : TRUE

-  On main report for each subreport right click and add subreport Parameter : LEVEL   expression:  $F{Level}

-  On main report add parameter : SUBREPORT_DIR  default value expression : "./"

Good Luck.

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...