Features Added in FOCUS 7.6.9

In this section:

Starting in FOCUS 7.6.9, you can extend underlines to the data in a column for styled output formats and display the total number of pages within a sort group.


Top of page

x
Extending Underlines to Data

How to:

Reference:

By default, underlines for column titles on a report extend only from the beginning to the end of the column title text. You can extend the underline to the entire report column in styled report output using the EXTUNDERLINE option in your FOCUS StyleSheet. EXTUNDERLINE is an option of the STYLE attribute for the TITLE report component. It is supported for formats DHTML, PDF, PS, and PPT.



x
Syntax: How to Extend an Underline to the Entire Report Column
TYPE = TITLE, [COLUMN = colspec,] STYLE = [+|-]EXTUNDERLINE  ,$

where:

colspec

Is any valid column specification.

+EXTUNDERLINE

Adds the EXTUNDERLINE option to the inherited text style or specifies a combination of text styles (for example, STYLE=BOLD+UNDERLINE).

-EXTUNDERLINE

Removes the EXTUNDERLINE option from the inherited text style.



x
Reference: Usage Notes for the EXTUNDERLINE Attribute


Example: Extending an Underline to the Entire Report Column

The following request against the GGSALES data source sums dollar sales by city and by date:

DEFINE FILE GGSALES               
YEAR/YY = DATE;                   
MONTH/M = DATE;
END                               
TABLE FILE GGSALES                
SUM DOLLARS                   
BY DATE                           
BY CITY
WHERE YEAR EQ 1997                
WHERE MONTH FROM 01 TO 05
WHERE CITY EQ 'Seattle' OR 'San Francisco' OR 'Los Angeles'
ON TABLE SET PAGE NOPAGE
ON TABLE HOLD FORMAT DHTML
END

The output shows that only the column titles are underlined:

To underline entire columns, generate the output in a format that can be styled and use the EXTUNDERLINE option in the STYLE attribute for the TITLE component. For example, the following request creates DHTML output in which the column titles are in boldface and left justified, and the underline is extended to the entire report column:

DEFINE FILE GGSALES               
YEAR/YY = DATE;                   
MONTH/M = DATE;
END                               
TABLE FILE GGSALES                
SUM DOLLARS                   
BY DATE                           
BY CITY
WHERE YEAR EQ 1997                
WHERE MONTH FROM 01 TO 05
WHERE CITY EQ 'Seattle' OR 'San Francisco' OR 'Los Angeles'
ON TABLE SET PAGE NOPAGE
ON TABLE HOLD FORMAT DHTML
ON TABLE SET STYLE *               
TYPE=TITLE, STYLE= BOLD +EXTUNDERLINE, JUSTIFY=LEFT $   
ENDSTYLE
END

The output is:

The following version of the request makes the EXTUNDERLINE and JUSTIFY=LEFT options the default for the TITLE component, then makes the Date column title bold and removes the extended underline from that column:

DEFINE FILE GGSALES               
YEAR/YY = DATE;                   
MONTH/M = DATE;
END                               
TABLE FILE GGSALES                
SUM DOLLARS AS 'Sales'                   
BY DATE                           
BY CITY
WHERE YEAR EQ 1997                
WHERE MONTH FROM 01 TO 05
WHERE CITY EQ 'Seattle' OR 'San Francisco' OR 'Los Angeles'
ON TABLE SET PAGE NOPAGE
ON TABLE HOLD FORMAT DHTML
ON TABLE SET STYLE *               
TYPE=TITLE,STYLE= EXTUNDERLINE, JUSTIFY=LEFT ,$   
TYPE=TITLE,COLUMN= DATE, STYLE= -EXTUNDERLINE +BOLD ,$   
ENDSTYLE                          
END

The output is:


Top of page

x
Displaying the Total Number of Pages in a Sort Group: <BYLASTPAGE

How to:

You can use the <BYLASTPAGE variable in a heading or footing to display the number of pages of output within each sort group when a report uses the REPAGE option to reset the page numbers for each sort group. This variable can only be used with styled output formats.

If the REPAGE option is not used in the report, the total number of pages in the report (<TABLASTPAGE variable) is used for <BYLASTPAGE.



x
Syntax: How to Display the Total Number of Pages Within Each Sort Group

The request must have the following syntax and hold the output in a styled output format:

BY sortfield PAGE-BREAK REPAGE

The heading or footing can use the following syntax to display “Page x of y

{HEADING|FOOTING} 
"Page <TABPAGENO of <BYLASTPAGE"

where:

sortfield

Is the sort field that has the REPAGE option. A PAGE-BREAK is required on the same sort field or a lower level sort field. PAGE-BREAK starts a new page for each sort break. REPAGE resets the page number to 1 for each sort break.

<TABPAGENO

Is the current page number.

<BYLASTPAGE

Is the last page number before the repage.



Example: Paginating Within a Sort Group

The following request against the GGSALES data source sorts by product, region, category, and city. It resets the pagination each time the product changes. The heading prints the current page number and the total within each product group:

TABLE FILE GGSALES
HEADING CENTER  
"<PRODUCT : Page <TABPAGENO of <BYLASTPAGE " SUM UNITS 
BY PRODUCT NOPRINT REPAGE
BY REGION PAGE-BREAK
BY CATEGORY
BY CITY
ON TABLE HOLD FORMAT PDF
END

The following partial output shows that the page number resets to 1 when the product changes and that the BYLASTPAGE variable displays the total number of pages for each product:


Information Builders