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 hierarchy is determined by the order in which the sort fields are specified in the request.
Note: The Table of Contents option is available for the HTML, HTML active report, active report with Adobe Flash Player (FLEX), Excel, Default, and User output formats.
The TOC also enhances the display of groups of data. You can view one section (or page) of a report at a time, or you can view all sections at once. You can control this feature with a page break. For more information, see Customizing Report Sections for Display.
The TOC displays all values of the first (highest level) vertical sort field, as well as the values of any lower level By fields designated for inclusion. These values appear as an expandable series of links or as a series of list controls. Unless otherwise specified in the request, a new section begins when the highest level sort field changes.
The display of data for a lower level sort field is controlled by your selection of a higher level sort field value. For example, in a report sorted first by country and then by car model, if you choose Italy from the TOC for country, you will only see a listing of Italian car models in the TOC for cars. Cars produced in other countries are not displayed.
Using the TOC, you can:
The TOC itself is an object that initially appears in the upper-left corner of the report, or as one or more drop-down lists in a page heading or footing or a report heading or footing.
For more information, see:
Tip: Click the Properties tab in the Object Inspector to verify that the Table of Contents is turned on.
or
You may add a single-level TOC to a Report or to a Page Heading.
Tip: To verify that the output format is set to HTML, click the Options button and ensure that HTML appears in the Select Format drop-down list.
Note: If heading is selected, the PLANT field is inserted into the page heading.
Note: If adding a TOC as a page heading, enter SALES REPORT before the <PLANT field.
For a Report, the TOC object appears in the upper-left corner, as shown in the following image.
For a Page Heading, the TOC appears in the page heading drop-down list. Expand the drop-down list to display the sort values for PLANT and the viewing options.
You can move the TOC anywhere on the screen by clicking the blue area above the Table of Contents and then dragging the TOC. You can also move it by double-clicking a location in the report at which to position the TOC.
You have the following options:
Tip: You can customize the look and feel of the TOC object by editing a .css file. Go to \ibi\DevStudioxx\ibi_html\javaassist\intl\En\toc.css. Do not forget to make a backup copy.
Note: To display all columns of data so that they have the same width, use one of the following options:
How to: |
If you select a value in a multi-level TOC, that value flashes (it is highlighted in gray) to draw attention to it. It also moves to the top of the window for viewing.
If the selected value is already viewable in the window, and the remaining report will fit in the window, the value flashes, but the report does not scroll.
In this example, you will add a dynamic HTML TOC as an object in the upper-left corner of a report and display a hierarchy consisting of multiple levels of sort fields, beginning with the highest level.
Tip: To verify that the output format is set to HTML, click the Options button, and ensure that HTML appears in the Select Format drop-down list.
The TOC appears in the upper-left corner, as shown in the following image.
Scroll back to the top of the report. Select AMERICAS. Your selection flashes to highlight it in the window. If you scroll down now, you will see that the report contains values only for the Americas.
The field values ARGENTINA and BRAZIL are listed in the TOC. These are values of COUNTRY. To see the field name of a value in the TOC, place the cursor over that value.
To generate a lengthy report for the purpose of illustration, this example prints the field PROJECTED_RETURN (that is, it uses the Detail function for the field).
Tip: To verify that the output format is set to HTML, click the Options button, and ensure that HTML appears in the Select Format drop-down list.
These fields are inserted in the page heading.
Note: When adding TOC to a heading, add additional page breaks to lower-level sort fields to group the hierarchical data correctly.
PROJECTED RETURN For: <SHORT.SHORT.CONTINENT For: <SHORT.SHORT.REGION For: <SHORT.SHORT.COUNTRY
Change the font size of the second line to 10.
The selected value, NORTH AMERICA, flashes and moves to the top of the window. From there you can scroll to see the related data, as shown in the following image.
If you select information already in your field of view, the value will flash to draw your attention to that location, but the display will not change.
Data in a report with a TOC is grouped into sections based on the sort fields.
You can customize each section with a page break. By default, a page break is included in the first (highest level) sort field. You can add page breaks to create additional sections and group the data based on a lower level sort field.
To generate a lengthy report for the purpose of illustration, this example prints the field PROJECTED_RETURN (that is, it uses the Detail function for the field).
Tip: To verify that the output format is set to HTML, click the Options button and ensure that HTML appears in the Select Format drop-down list.
This step generates a page break on the report each time the value of HOLDER changes.
Double-click the TOC to expand it, and move it outside the report data, as shown in the following image.
The TOC feature:
Note:
WebFOCUS |