Impossible!

Hello everybody,

 

I've been looking for a solution for this kind of figure many years ago, from ireport designer 2.00 to ireport 6.00++ and i've never found a solution !

Please help, image below :

https://imgur.com/a/xwE1B

 

 

 

j2eealidev's picture
Joined: Jun 3 2013 - 8:32am
Last seen: 5 years 10 months ago

3 Answers:

I am not sure if it would work as I did not test it, but on top of my head use print when expression. 
So maybe use the row count parameter or maybe just cound the rows and use maths to always ensure epxression is true when values is in the half of the row count. 
Otherwise if print when messes up the visual of the report, maybe just add expression where when halve of row count is true then "print this" : ""  (which wil lbe blank space) 

Hoe this helps, if not, then atleast I tried to answer your question. 

joseng62's picture
6929
Joined: Dec 5 2014 - 2:43am
Last seen: 8 months 4 days ago

Hello,

 

Thank you for your return, however, your solution could work only if the numbers of lines are : ODD, what about if numbers of lines are pair ??

 

ODD = example : 3    5     7      9    ...

Pair = example : 2  4 6  8  10  12...

j2eealidev's picture
Joined: Jun 3 2013 - 8:32am
Last seen: 5 years 10 months ago

Well yeah, for odd it would be easy casue the middle of 3 would be 2 and visualy it would look great. 

Pair,(even) you need to decided what would be the middle.
So if rowcount = 4
in print when would be =         
printVar =      (rowcount % 2 == 0) ? rowcount / 2 + 1  : rowcount / 2   (You can decided -1 or + 1 )
Depending on the number data type you use. You could round to the highest or lowest number. 
Then in the print when you could state printVar == $V{REPORT_COUNT}

Something like that, you would need to play around a bit

joseng62's picture
6929
Joined: Dec 5 2014 - 2:43am
Last seen: 8 months 4 days ago
Feedback
randomness