Distributing a TOC Report Using ReportCaster

In this section:

How to:

You can enhance navigation within a large HTML report by adding a dynamic HTML-based Table of Contents (TOC). To take advantage of this feature, the report must contain at least one vertical sort (BY) field. If you include more than one sort field in a report, the order in which the sort fields are specified in the request determines the hierarchy. To add a TOC for a lower-level sort field, you must also add a TOC for its parent.

The TOC displays, as hyperlinks, all values of the first (highest-level) vertical sort field, as well as the values of any lower level BY fields that you designate for inclusion. Unless otherwise specified in the request, a new page begins when the highest-level sort field changes.

Note:


Top of page

x
Syntax: How to Distribute a TOC Report Using ReportCaster

To distribute a TOC report using ReportCaster, add the following code in the procedure:

SET BASEURL=http://hostname

where:

hostname

Is the host name of the Web server on which the WebFOCUS Client is installed.

For example:

SET BASEURL=http://server1/ 
SET PAGE-NUM=OFF
TABLE FILE CENTORD
HEADING
"Sales Report"
" "
SUM LINEPRICE AS 'Sales'
BY PLANT
BY PRODCAT
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
TYPE=REPORT, GRID=OFF, FONT=ARIAL, SIZE=12, $
TYPE=HEADING, SIZE=16, $
ENDSTYLE
ON TABLE SET COMPOUND BYTOC
END

The following image shows an HTML report containing a dynamic HTML-based TOC in the upper left corner. After it is created, ReportCaster can distribute this report.

HTML report image


Top of page

x
Distributing an EXL2K TOC Report

If a report that generates an EXL2K TOC in Managed Reporting is only generating the first sheet when distributed by ReportCaster, this is because ReportCaster is not processing the BYTOC request properly. As a workaround, add SET ONLINE-FMT=EXL2K to ensure that the BYTOC request is processed. For example:

SET BASEURL=http://webserver:port/
SET COMPOUND=BYTOC 
SET ONLINE-FMT=EXL2K 
 
TABLE FILE CAR
PRINT SALES AS 'Sales'
BY MODEL
BY CAR
HEADING
"Sales Report"
" "
ON TABLE SET PAGE-NUM OFF
ON TABLE SET BYDISPLAY ON
ON TABLE NOTOTAL
-*ON TABLE PCHOLD FORMAT EXL2K
END

WebFOCUS