[SOLVED] How to mark borders around fields in Header section of HTML and PDF report?
Hi,
Can anyone help me out in marking borders around some of the fields in the Header section of my HTML & PDF reports in WebFocus?
I have tried using HGRID & VGRID attributes for marking borders in PDF report, which didn't work out.
Below is the mock-up of the report which shows the REPORT HEADING, HEADER portion & DETAIL portion.I wanted to put the below shown 2 fields(FE DATE & FE Score, which exists in the HEADER portion of the report) along with their values together in a single box(require borders in both HTML & PDF reports).
FE DATE: 10/10/2008 FE Score: YELLOW - 85.72
MOCK-UP OF THE REPORT
HEADING OF THE REPORT:
FACTORY SCORE CARD
HEADER PORTION OF THE REPORT:
Factory Status: YELLOW % Accept Sampled Units: 96.2% Factory Name: PT. Dream Sentosa Indonesia % Passed Inspections: 98.97% Factory ID: 1234 On-time Inspection: 99.27% Factory Addr: Mangga Besar 2 Rt 16/04 Walahar, Klari, Building 1,2, 1/F- 4, 2/F-5,Jawa Barat (West Java),Karawang,Indonesia #Market Withdrawals: TBD FE DATE: 10/10/2008 FE Score: YELLOW - 85.72 DETAIL PORTION OF THE REPORT:
Kindly give me some tips on what attributes can be used for marking borders if anybody knows..
Thanks & Regards Tejovathi.SThis message has been edited. Last edited by: Kerry,
December 17, 2008, 10:15 AM
Francis Mariani
Unfortunately, you cannot add borders to specific pieces of a HEADING, you can't even do it for one line in the HEADING, it's either the whole HEADING or nothing.
You can, however, change the style or color or background color:
TABLE FILE CAR
SUM
SALES
SEATS NOPRINT
BY COUNTRY
BY CAR
BY MODEL
HEADING
"WEBFOCUS REPORT"
"FE DATE: <CAR"
"FE SCORE <SEATS"
WHERE READLIMIT EQ 100
WHERE RECORDLIMIT EQ 100
ON TABLE SET PAGE NOLEAD
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLESHEET *
FONT='ARIAL', SIZE=8, GRID=OFF, $
TYPE=HEADING, HEADALIGN=BODY, $
TYPE=HEADING, LINE=2, BACKCOLOR=RED, $
TYPE=HEADING, LINE=3, BACKCOLOR=RED, $
ENDSTYLE
END
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
December 17, 2008, 10:25 AM
<JG>
to expand on the post from Francis
TABLE FILE CAR
"MY HEADING"
"COUNTRY <COUNTRY <+0>"
SUM DCOST RCOST
BY COUNTRY
BY CAR
BY MODEL
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
TYPE=REPORT,GRID=OFF,$
TYPE=HEADING,LINE=2,ITEM=1,BACKCOLOR=SILVER,$
TYPE=HEADING,LINE=2,ITEM=2,BACKCOLOR=SILVER,$
ENDSTYLE
END
the <+0> is important for PDF otherwise the colour will be for the whole line
and not the 2 cells you are interested in.
December 17, 2008, 11:50 PM
Anoop
Expanding JG post the border can be done for html output but dont know the way to do it for pdf , try this it might be helpfull
DEFINE FILE CAR TAB/A1000='<table border="1" width="50%" id="table1" style="border-collapse: collapse" bordercolor="#000000"><tr><td>COUNTRY '|COUNTRY|'</td></tr></table>'; END TABLE FILE CAR "MY HEADING" "<TAB <+0>" SUM DCOST RCOST BY COUNTRY BY CAR BY MODEL ON TABLE PCHOLD FORMAT HTML ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE * TYPE=REPORT,GRID=OFF,$ TYPE=HEADING,LINE=2,ITEM=1,BACKCOLOR=SILVER,$ TYPE=HEADING,LINE=2,ITEM=2,BACKCOLOR=SILVER,$ ENDSTYLE END
WebFOCUS 7.0.4 Windows XP HTML PDF EXCEL
December 18, 2008, 12:52 PM
Doug
Actually, you can. I did this at Chubb Insurance and it worked out quite nicely. you need to greate image of specific sizes (this can be done in MS Paint). My naming conventions are xLxxxzzz where "x" is either 'H' or 'V" (Horizontal or Vertical), L is for Line, xxx is the horizontal length and zzz is the vertical height. Either xxx or zzz is 001 in both cases. Oncen these are created you can add the following lines to you STYLE senction:
Your need to play with the POSITION and tweak it till it gets to where you want it. Once that's done, these "borders" are statically located in your report. It's what they required and it's what I delivered.
In FOCUS Since 1983 ~ from FOCUS to WebFOCUS. Current: WebFOCUS Administrator at FIS Worldpay | 8204, 8206
December 18, 2008, 01:04 PM
Francis Mariani
Will this work if the width of the cell changes depending on the data contained within it?
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
December 18, 2008, 03:52 PM
Waz
You should be able to add borders in HTML with CSS.
With PDF, you could try using the the stylesheet option OBJECT=BOX. It is limited and fixed, have a search in the forum.
Waz...
Prod:
WebFOCUS 7.6.10/8.1.04
Upgrade:
WebFOCUS 8.2.07
OS:
Linux
Outputs:
HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!
December 18, 2008, 04:59 PM
FrankDutch
It depends on the version you are using but in 7.6.6 you can put a grid in your heading and change the bg color of each cell. Change the character color and size. I'm not sure about the borders.
Frank
prod: WF 7.6.10 platform Windows, databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7 test: WF 7.6.10 on the same platform and databases,IE7