I am trying to based on &WFFMT on whether to use which image path to cater for PDF and HTML, but it seems it is not working. Can you guys help to see what went wrong.
-SET &PDFIMGURL = 'logo.gif';
-SET &HTMLIMGURL = '/approot/test/logo.gif';
JOIN
INNER CUST.CUST.IPKIPN IN CUST TO MULTIPLE APPL.APPL.ANKIPN IN APPL TAG J0
AS J0
END
DEFINE FILE CUST
FLAG/A1 = IF &WFFMT EQ HTML THEN '1' ELSE '0';
MALE/I7 = IF IPSEX EQ 1 THEN + 1 ELSE + 0;
FEMALE/I7 = IF IPSEX EQ 2 THEN + 1 ELSE + 0;
END
TABLE FILE CUST
SUM
'CUST.CUST.MALE' AS 'Male'
'CUST.CUST.FEMALE' AS 'Female'
BY 'CUST.CUST.AGERANGE' AS 'Age Range'
ON TABLE SUBHEAD
" "
" "
HEADING
"APPLICATION APPROVED FROM <+0>&dateFrom <+0>TO<+0> <+0>&dateTo"
" "
"AGE VS GENDER"
" "
FOOTING
" "
" "
" "
"Private & Confidential"
"Report Generated On <+0>&DATEtrDMYY<+0> "
ON TABLE SET PAGE-NUM ON
ON TABLE ROW-TOTAL/I11 AS 'Total'
ON TABLE SUMMARIZE AS 'Total'
ON TABLE PCHOLD FORMAT &WFFMT
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
UNITS=IN,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
PAGECOLOR=RGB(245 245 245),
$
TYPE=TABHEADING,
SIZE=12,
STYLE=BOLD,
$
TYPE=TABHEADING,
IMAGE=&HTMLIMGURL,
POSITION=(+0.055556 -0.027778),
SIZE=(1.680556 0.402778),
WHEN=FLAG EQ '1',
$
TYPE=TABHEADING,
IMAGE=&PDFIMGURL,
POSITION=(+0.055556 -0.027778),
SIZE=(1.680556 0.402778),
WHEN=FLAG EQ '0',
$
Thank you in advance.
Regards, Kevin TongThis message has been edited. Last edited by: Kevin Tong,
WebFOCUS 7.6.9 Windows 2003, all output
May 06, 2010, 06:11 AM
Dan Satchell
Both images need to be somewhere in your APP path. Give them different names to avoid confusion - for example html.gif and pdf.gif. You can eliminate the DEFINEd FLAG and WHEN clause in the stylesheet by making the logo decision with Dialogue Manager: