Facilitating Report Manipulation

In this section:

Normally, a web server returns an entire report to a browser. The browser waits until it receives all of the report before displaying it.

On-demand paging allows you to download one page of a report that is up to 99999 pages long to a browser instead of downloading the entire report at once. The web server holds the remaining pages until the user requests them. This feature shortens the time the user waits to see the first page of a report. It is especially effective for long reports.

On-demand paging is implemented in the WebFOCUS Viewer. It requires that report output be formatted as HTML, which is the default setting for a request submitted through the WebFOCUS Client.

The following is a report displayed in the WebFOCUS Viewer.

WebFOCUS viewer report diagram


Top of page

x
Navigating a Report With the WebFOCUS Viewer

How to:

When you run a report designated for On-Demand Paging, the WebFOCUS Viewer opens automatically and displays the first page of the report. The Viewer consists of two panes: the Report Pane and the Viewer Control Panel, as shown in the following image.

Report Pane and the Viewer Control Panel

The Report Pane is the larger pane and contains one page of report output. When you first run a report, the Report Pane contains the first page of report output. The Viewer Control Panel contains the controls that allow you to display specific pages, deliver the entire report to your web server, and search your document for particular strings of information.



x
Syntax: How to Enable the WebFOCUS Viewer
SET WEBVIEWER = {OFF|ON}

or

ON TABLE SET WEBVIEWER {OFF|ON}

where:

OFF

Disables on-demand paging. WebFOCUS downloads the entire report to a standard browser window. OFF is the default value.

ON

Enables on-demand paging. WebFOCUS downloads the first page of a report to the browser in the WebFOCUS Viewer. The number of lines displayed at one time depends on Windows desktop settings (resolution).



Example: Enabling the WebFOCUS Viewer

The procedure and launch page for this example are run in WebFOCUS. They must be tested and run in this environment.

  1. Create a procedure named ONDEMAND, which displays an order report for a store in the WebFOCUS Viewer.

    Procedure:

    SET WEBVIEWER=ON
    TABLE FILE CENTORD
    PRINT ORDER_NUM ORDER_DATE
    BY STORE_CODE
    WHERE STORE_CODE EQ '1003DC'
    ON TABLE SET PAGE-NUM OFF
    ON TABLE SET STYLE *
    TYPE=REPORT, GRID=OFF,$
    ENDSTYLE
    END
  2. Create a launch page from which a user can run the report.
  3. Run the launch page, and click the link. The report displays in the WebFOCUS Viewer.

    WebFOCUS Viewer diagram


Top of page

x
Opening and Closing the WebFOCUS Viewer

How to:

Reference:

You can specify a target frame in which to open the WebFOCUS Viewer, and a home page that displays when you close the WebFOCUS Viewer.



x
Syntax: How to Open the WebFOCUS Viewer in a Target Frame
SET WEBVIEWTARG = {target_frame|OFF}

where:

target_frame

Is the name of an existing frame in the browser or one of the following reserved HTML target frames:

_blank

Opens the WebFOCUS Viewer in a new browser window. This is the default for reports that do not have accessibility enabled.

_self

Opens the WebFOCUS Viewer in the same frame as the anchor.

_parent

Opens the WebFOCUS Viewer in the immediate parent frame that contains the anchor.

_top

Opens the WebFOCUS Viewer in the current browser window.

OFF

Opens the WebFOCUS Viewer in the frame from which you ran the report. This is the default for reports that have accessibility enabled.

Note: For more information on enabling accessibility, see ACCESSPDF.



x
Syntax: How to Display a Home Page When You Close the WebFOCUS Viewer
SET WEBVIEWHOME = {home_URL|OFF}

where:

home_URL

Is a valid URL that displays an HTML page when you close the WebFOCUS Viewer.

OFF

Displays a blank browser window when you close the WebFOCUS Viewer. You must enter another URL to run another report. OFF is the default value.



x
Reference: Closing the WebFOCUS Viewer

The Close button, located on the Control Frame, closes the WebFOCUS Viewer and removes the report from the web server. The page the browser displays next depends on the WEBVIEWTARG and the WEBVIEWHOME settings, as follows:


Top of page

x
Controlling Button Display on the WebFOCUS Viewer

How to:

You can issue commands that specify whether the WebFOCUS Viewer displays the Close, Help, and All Pages buttons.



x
Syntax: How to Control Whether The Close Button Displays
SET WEBVIEWCLOSE = {OFF|ON}

or

ON TABLE SET WEBVIEWCLOSE {OFF|ON}

where:

ON

Displays the Close button. ON is the default value.

OFF

Does not display the Close button.



x
Syntax: How to Control Whether The Help Button Displays
SET WEBVIEWHELP = {OFF|ON}

or

ON TABLE SET WEBVIEWHELP {OFF|ON}

where:

ON

Displays the Help button. ON is the default value.

OFF

Does not display the Help button.



x
Syntax: How to Control Whether The All Pages Button Displays
SET WEBVIEWALLPG = {OFF|ON}

or

ON TABLE SET WEBVIEWALLPG {OFF|ON}

where:

ON

Displays the All Pages button. ON is the default value.

OFF

Does not display the All Pages button.



x
Procedure: How to Enable the Goto Last Page Button
  1. From Internet Explorer, click the Tools menu and select Internet Options.
  2. The Internet Options dialog box opens.
  3. From the Temporary Internet files box, click Settings.

    The Settings dialog box opens.

  4. Click the Every visit to the page radio button.
  5. Click OK to apply the change and exit the Settings dialog box.
  6. Click OK to exit the Internet Options dialog box.

Top of page

x
Using the Viewer Control Panel

In this section:

How to:

The Viewer Control Panel, as shown in the following image, (located at the bottom of the window) contains the controls you use to navigate through the report and to search for a string in the report. The Viewer Control Panel navigational controls allow you to display the next or previous page, the first or last page, or a specific page. You use the searching function to have the Viewer locate a search string you specify within all report pages.

The Viewer Control Panel

Note: When specifying a search string, you must specify the actual number of spaces between characters because HTML displays a single space, even when multiple spaces are used between characters.



x
Procedure: How to Navigate Through a Report

The Viewer Control Panel offers several ways to view pages in your report:



x
Searching a Report

The Viewer Control Panel contains controls that offer several ways to search your report. Using the Viewer search controls, you can select a string of information, such as a phrase that occurs in your report or a group of numbers, and search for each occurrence of that string. You can further customize your search by matching capitalization of words exactly (a case-sensitive search) or by controlling the direction of your search (either forward or backward from your starting point in the report). Use these controls to search your report:



x
Procedure: How to Search the Report
  1. Enter the string in the Search input box.
  2. Click Match Case if you want to perform a case-sensitive search.

    Notice that the WebFOCUS Viewer displays the Match Case button with a red line across it to indicate that it is active.

  3. To begin your search, click:
    1. Search Backward to search for the string from the current page back to the first page.

      Or

    2. Find to search from the current page to the end of your report.

    The WebFOCUS Viewer searches the report and underlines the first occurrence of the string.

  4. Click Find again to search for another occurrence of the string.


Example: Using the Viewer Control Panel to Search

You want to use the Viewer Control Panel to navigate a long report called Coffee Sales to find occurrences of the string "Kona," a type of coffee that you sell. After you run the report, WebFOCUS displays the first page of the report in the Viewer.

  1. To search for sales of Kona, type Kona in the input box and click Find, as shown in the following image.

    Find image

    The WebFOCUS Viewer returns your report with the first occurrence of your search string underlined, as shown in the following image.

    Viewer returns report

  2. Click Find again to locate the next occurrence of Kona.


x
Procedure: How to Customize Search Results With a Cascading Style Sheet

The WebFOCUS Viewer searches the report and underlines the first occurrence of the text string found. You may customize the search results by applying a Cascading Style Sheet (CSS) with a color and/or style defined.

  1. Open a new text file by using a third-party text editor, such as Notepad.
  2. Type the following example Cascading Style Sheet (CSS) code:
    BODY {
     font : x-small Verdana, Arial, Helvetica;
     }
     U {
     background : Blue;
     text-decoration : none;
     color : White;
     font : bold;
     }

    In the CSS example code above, underlined text in the body of the report will be changed to set the background color to Blue, set the text to bold, and set the text color to White.

  3. Save the file as a Cascading Style Sheet (.css).

    Note: Type .css as the file extension. For example, findcolor.css.

    The location in which to save the CSS file depends on the WebFOCUS environment you are working in.

    Note: CSS files are accessed from a web accessible location. For WebFOCUS and Developer Studio installations, the /ibi_apps/ibi_html alias is a location in which web accessible content can be stored.

    1. If you are working in Developer Studio local project environment, save the CSS file in the \ibi\DevStudioxx\ibi_apps\ibi_html directory, where xx is the Developer Studio release number. You may specify the URL to the CSS file within the Report Painter reporting tool. In the Style tab of the Report Options dialog box (for HTML format), select Style File Selection and enter the URL value in the External Cascading Stylesheet URL input field. For example: /ibi_apps/ibi_html/findcolor.css.
    2. If you are using Developer Studio connected to a remote WebFOCUS environment, or not using Developer Studio but coding a self-service FEX, then save the CSS file in the \ibi\WebFOCUSxx\ibi_apps\ibi_html directory, where xx is the WebFOCUS release number.
    3. If you are working in Managed Reporting, the CSS file can be imported into the Managed Reporting domain. Once imported, it will be located in the Other Files folder. The reporting tools provide an option to select a Cascading Style Sheet file within the Managed Reporting domain. You can select the CSS file in the reporting tools from Report Options or Report Properties.
  4. Open your report in InfoAssist, or the Text Editor, and apply the Cascading Style Sheet. For information on InfoAssist, see the WebFOCUS InfoAssist User’s Manual.

    In the following code, the findcolor.css Cascading Style Sheet file is applied to the report:

    TABLE FILE CAR
    PRINT CAR MODEL SEATS
    BY COUNTRY
    ON TABLE SET WEBVIEWER ON
    ON TABLE SET STYLE *
    CSSURL=/ibi_apps/ibi_html/findcolor.css, $
    ENDSTYLE
    END 

    Note: Fully qualify the URL to the CSS file when the CSS file is located on a different web location than the WebFOCUS environment you are running the report from. For example: CSSURL=http://hostname[:port]/ibi_apps/ibi_html/findcolor.css $, where hostname[:port] is the host name and port number of the web or application server the CSS file is accessible from.

  5. Run the report.
  6. Enter the string in the Search input box and click Find.

    The WebFOCUS Viewer searches the report and highlights the first occurrence of the string found in blue. In the example below, a report using the findcolor.css Cascading Style Sheet file searches for and finds DOOR by highlighting the word in blue.

    Report using Cascading Style Sheet


Top of page

x
Printing With On-Demand Paging

How to:

You must clear the browser cache before printing a report locally using the Print button on the browser toolbar. You must also activate the window by clicking it before using the Print button.

Use the procedure that applies to your browser to clear the cache.



x
Procedure: How to Clear the Cache in Microsoft Internet Explorer
  1. Select Internet Options from the Tools menu.
  2. On the General tab, for Temporary Internet Files, select Delete Files.

WebFOCUS