Focal Point
[CLOSED] Grandtotal with GRID in PDF

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/283106531

June 01, 2009, 03:52 PM
ChannyS
[CLOSED] Grandtotal with GRID in PDF
Anyone know how to make the border on this grand total look decent?

 

TABLE FILE CAR
SUM 
     CAR
     BODYTYPE
     LENGTH
     WIDTH
     FUEL_CAP
     WEIGHT
     WEIGHT
ON TABLE COLUMN-TOTAL AS 'TOTAL'
ON TABLE PCHOLD FORMAT PDF

ON TABLE SET STYLE *
     UNITS=IN,
     SQUEEZE=ON,
     ORIENTATION=PORTRAIT,
	 GRID=ON,
$
TYPE=REPORT,
     FONT='TIMES NEW ROMAN',
     SIZE=10,
$
ENDSTYLE
END
 

This message has been edited. Last edited by: Kerry,


Release: WebFOCUS 7.6.8
OS: Windows
Output formats: HTML, PDF, Excel, csv
June 01, 2009, 04:24 PM
Prarie
Go here

and look toward the bottom at Mickey's article on styling PDF reports. It's a good article with lots of useful stuff.
June 01, 2009, 04:30 PM
ChannyS
Thanks. I will review his article.


Release: WebFOCUS 7.6.8
OS: Windows
Output formats: HTML, PDF, Excel, csv
June 01, 2009, 04:33 PM
Francis Mariani
Unfortunately, I can't see how we can fix the border problem...


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
June 01, 2009, 04:40 PM
ChannyS
Just curious what you might to do 'ease the pain' for users who have to look at something like this?!?


Release: WebFOCUS 7.6.8
OS: Windows
Output formats: HTML, PDF, Excel, csv
June 01, 2009, 05:46 PM
Prarie
Do you have to have the Grid ON?

TABLE FILE CAR
SUM 
     CAR
     BODYTYPE
     LENGTH
     WIDTH
     FUEL_CAP
     WEIGHT
     WEIGHT
ON TABLE SUBFOOT
" "
"TOTAL <ST.WEIGHT"
ON TABLE PCHOLD FORMAT PDF

ON TABLE SET STYLE *
     UNITS=IN,
     SQUEEZE=ON,
     ORIENTATION=PORTRAIT,
-*	 GRID=ON,
$
 
 TYPE=TABFOOTING,       
	 BORDER-TOP=LIGHT,
	  BORDER-BOTTOM=LIGHT,
	  BORDER-RIGHT=LIGHT,
	   BORDER-LEFT=LIGHT,$
ENDSTYLE
END  

June 02, 2009, 09:42 AM
ChannyS
Thanks for the idea. When it becomes the subfoot then it kind of gets 'separated' with the borders or grids on...


Release: WebFOCUS 7.6.8
OS: Windows
Output formats: HTML, PDF, Excel, csv
June 02, 2009, 02:09 PM
susannah
BORDER-BOTTOM i can never get to work
ever!
i want double underlines under subtotals...
never happens!
never!
BORDER-BOTTOM-STYLE=DOUBLE is what the doc says.
ha!




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
June 02, 2009, 02:18 PM
ChannyS
I think that some of these things actually have to do with what I call the 'border wars'. They have to make decisions when elements touch each other as to how to handle the borders:

1. If both had the same border, do you double the border or combine them as one?
2. If only one of the elements has a border and the other doesn't, who wins (hence the war...)?

etc. etc.

Now, if I could actually figure out the rules, maybe I could work around it. I can't find consistency at all. And... even if there are rules I can say I think there are bugs. Because sometimes my right most columns which have nothing to the right of them (well duh!) don't get their borders painted. Then I remove a sub-element (which doesn't abet on the right - only on the top or bottom) and bingo the border is back. So, for the most part I try to stick to grids which seem to be more consistent. However, in the case of the grandtotal it seems that even the grid isn't quite right.


Release: WebFOCUS 7.6.8
OS: Windows
Output formats: HTML, PDF, Excel, csv
June 02, 2009, 02:54 PM
mgrackin
Susannah,

If my memory serves me right, the options for BORDER-STYLE are different depending on the output format HTML vs PDF. HTML offers a few more options which are not supported by PDF. However, I am not sure if the double border is supported by PDF or not.


Thanks!

Mickey

FOCUS/WebFOCUS 1990 - 2011
June 02, 2009, 07:02 PM
susannah
output doesn't matter
border-bottom just doesn't work




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
June 03, 2009, 09:06 AM
PBrightwell
Have you tried recap and subfoot rather than column-total?


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
June 03, 2009, 02:12 PM
Doug
Do you want something like this? If so, add a background color (I used GRAY) and a bold style for my GRANDTOTAL while using COLUMN-TOTAL. ... No Borders...
June 03, 2009, 05:19 PM
ChannyS
Was there a BY in report that enabled you to get the 'TOTAL' word on the same line?


Release: WebFOCUS 7.6.8
OS: Windows
Output formats: HTML, PDF, Excel, csv
June 03, 2009, 05:56 PM
Doug
Yes, actually there is a "BY CAR" in there. However, that's not the reason that the TOTAL is on a line above the total VALUES.

Try your code twice, once with "WHERE CAR EQ 'BMW'" and once without the WHERE statement. You'll see the difference. It's due to the width of the first colum, CAR, column. So, with that in mind, you can (and I've done this before) increase the width (SQUEEZE) of the first column to accomodate the word "TOTAL".
TYPE=REPORT, COLUMN=(FIRST COLUMN), SQUEEZE=1.0,$





   In FOCUS Since 1983 ~ from FOCUS to WebFOCUS.
   Current: WebFOCUS Administrator at FIS Worldpay | 8204, 8206
June 03, 2009, 08:24 PM
susannah
hey north carolina!
are you comming over to Summit next week?




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
June 04, 2009, 10:23 AM
ChannyS
quote:
Originally posted by Doug:
Yes, actually there is a "BY CAR" in there. However, that's not the reason that the TOTAL is on a line above the total VALUES.

Try your code twice, once with "WHERE CAR EQ 'BMW'" and once without the WHERE statement. You'll see the difference. It's due to the width of the first colum, CAR, column. So, with that in mind, you can (and I've done this before) increase the width (SQUEEZE) of the first column to accomodate the word "TOTAL".
TYPE=REPORT, COLUMN=(FIRST COLUMN), SQUEEZE=1.0,$


I think you need both - the BY and the column to be wide enough. Without the BY they necessarily put it up one row - probably because they assume that every column can be totaled where as with a BY, the BY column would not be summed up.


Release: WebFOCUS 7.6.8
OS: Windows
Output formats: HTML, PDF, Excel, csv
June 04, 2009, 11:10 AM
Doug
It's a combination of things. Try the following code with and without the "BY CAR" or "WHERE CAR EQ 'BMW'" or "TYPE=REPORT, COLUMN=CAR, SQUEEZE=1.0, BACKCOLOR=RGB(255 255 210),$" or lines (one at a time).
TABLE FILE CAR
PRINT BODYTYPE LENGTH WIDTH FUEL_CAP WEIGHT
BY CAR
WHERE CAR EQ 'BMW'
ON TABLE COLUMN-TOTAL AS 'TOTAL'
ON TABLE PCHOLD FORMAT PDF
ON TABLE SET PAGE OFF
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
UNITS=IN, SQUEEZE=ON, ORIENTATION=PORTRAIT,  GRID=ON,$
TYPE=REPORT, FONT='TIMES NEW ROMAN', SIZE=10,$
TYPE=REPORT, COLUMN=CAR, SQUEEZE=1.0, BACKCOLOR=RGB(255 255 210),$
TYPE=GRANDTOTAL, BACKCOLOR=GRAY, STYLE=BOLD,$
ENDSTYLE
END
See what works the best for you in your requirement.
June 04, 2009, 11:26 AM
ChannyS
Thanks.

I don't seem to be able to get it right unless I have the BY.


Release: WebFOCUS 7.6.8
OS: Windows
Output formats: HTML, PDF, Excel, csv
June 04, 2009, 02:53 PM
Doug
I'd look at the results of a search for "total line". You can look at what I got as a result of that search here. I don't know what else to say and am a bit cramped for time at the moment.
Confused Good Luck, Doug
June 05, 2009, 09:27 PM
Doug
Susannah:
quote:
hey north carolina! are you comming over to Summit next week?
Yes I Am... Save me a seat...




   In FOCUS Since 1983 ~ from FOCUS to WebFOCUS.
   Current: WebFOCUS Administrator at FIS Worldpay | 8204, 8206