Focal Point
Solid double underline for Total in a SUBFOOT

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/8351095072

February 08, 2008, 12:19 PM
Watashi
Solid double underline for Total in a SUBFOOT
Need a technique, function or routine for solid double underlines for totals in a SUBFOOT similar to concatenated string of "="'s with horizontal space in-between without any vertical spaces, solid. This double underline should go under certain columns and not all the way across the report using absolute position with designated/control over the length.


7.7.02
Unix
HTLM
February 08, 2008, 03:25 PM
FrankDutch
Watashi

The solution for this highly depends on the way your columns are constructed.
Is it an across or just some fields.

And in what format are you reporting, HTML or PDF?


From the manual I copied this text. It specially is based on the FML part, but many things also work in "normal" reports
quote:

How to Add and Format Row and Cell Borders
To request a uniform border around a row or cell, use this syntax:
TYPE=REPORT, LABEL=row_label, [COLUMN=column,] BORDER=option,
[BORDER-STYLE=line_style,] [BORDER-COLOR={color|RGB(r g b)},] $
To specify different characteristics for the top, bottom, left, and/or right borders, use this
syntax
TYPE=REPORT, LABEL=row_label, [COLUMN=column,] BORDER-position=option,
[BORDER-[position-]STYLE=line_style,]
[BORDER-[position-]COLOR={color|RGB(r g b)},] $
To specify different characteristics for the top, bottom, left, and/or right borders, use this
syntax
TYPE=REPORT, LABEL=row_label, [COLUMN=column,] BORDER-position=option,
[BORDER-[position-]STYLE=line_style,]
[BORDER-[position-]COLOR={color|RGB(r g b)},] $
where:
row_label
Is the row to which the specified border characteristics are applied.
column
Used in conjunction with row label, designates a cell (at the point of intersection of the
row and the column) to which the specified border characteristics are applied.
option
Can be one of the following values:
ON turns borders on for the entire heading or footing. ON generates the same line as
MEDIUM.
OFF turns borders off for the entire heading or footing. OFF is the default.
LIGHT specifies a thin line. You can specify a light line for the entire heading or footing,
or for one or more border positions.
MEDIUM identifies a medium line (ON sets the line as MEDIUM). You can specify a light
line for the entire heading or footing, or for one or more border positions. Note that the
medium line setting ensures consistency with lines created with GRID attributes.
HEAVY identifies a thick line. You can specify a heavy line for the entire heading or footing,
or for one or more border positions.
width specifies the line width in points (where 72 pts=1 inch). You can specify a line
width in points for the entire heading or footing. or for one or more border positions.
Line width specified in points is displayed differently in HTML and PDF output. For uniform
appearance, regardless of display format, use LIGHT, MEDIUM, or HEAVY.
position
Specifies which border line to format. Valid values are: TOP, BOTTOM, LEFT, RIGHT.
You can specify a position qualifier for any of the BORDER keywords. This enables you
to format line width, line style, and line color individually, for any side of the border.
line_style
Sets the style of the border line. WebFOCUS StyleSheets support all of the standard
Cascading Style Sheets line styles. Several 3-dimensional styles are only available in
HTML, as noted by asterisks. Valid values are:
NONE
SOLID
DOTTED
DASHED
DOUBLE
GROOVE*
RIDGE*
INSET*
OUTSET*
color
Is one of the preset color values. The default value is BLACK.
If the display or output device does not support colors, it substitutes shades of gray.
RGB
Specifies the font color using a mixture of red, green, and blue.
(r g b)
Is the desired intensity of red, green, and blue, respectively. The values are on a scale
of 0 to 255, where 0 is the least intense and 255 is the most intense. Note that using
the three color components in equal intensities results in shades of gray.
Note: For HTML reports, the BORDERS feature requires that Cascading Style Sheets be
turned ON. This code is not required for PDF and PS reports.



Controlling the size of the underlining might be less easy...




Frank

prod: WF 7.6.10 platform Windows,
databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7
test: WF 7.6.10 on the same platform and databases,IE7

February 08, 2008, 04:27 PM
mgrackin
Frank,

I saw that is the doc as well but as you stated it only applies to FML. I am using WF 713 and there is no way to pick a "cell" in a SUBFOOT and apply a BORDER only to that "cell". I put quotes around the word cell because portions of the SUBFOOT are only locked into cells on a report when HEADLIGN=BODY is set.


Thanks!

Mickey

FOCUS/WebFOCUS 1990 - 2011
February 08, 2008, 04:43 PM
FrankDutch
Mickey

I created a report that should do something similar. I made the subtotals and totals by a few extra steps and adding them as extra records like this

SET ASNAMES=ON
TABLE FILE CAR
SUM SALES
BY COUNTRY AS LAND
ON TABLE HOLD AS HOLD1 
END
DEFINE FILE CAR
LAND/A20='TOTAL';
END
TABLE FILE CAR
SUM SALES
BY LAND
ON TABLE HOLD AS HOLD2
END



Now combine them with MORE and then I can controle the line with some WHEN commands, because in fact it is a normal field.




Frank

prod: WF 7.6.10 platform Windows,
databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7
test: WF 7.6.10 on the same platform and databases,IE7

February 08, 2008, 04:46 PM
Leah
Is your subfoot created and including your totals with spot markers? If so, then have you tried just 'spotting' the double underline on the report. I've done it with colum-subtotals and then played till the alignment was okay.

On... SUBFOOT
"    <25><CT.FIELD"
"    <25>========="



Leah
February 08, 2008, 04:54 PM
FrankDutch
Leah

your solution would work, but that is what he does not want seeing his question.

Frank




Frank

prod: WF 7.6.10 platform Windows,
databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7
test: WF 7.6.10 on the same platform and databases,IE7

February 08, 2008, 05:06 PM
Leah
Wouldn't it be nice if in WebFOCUS we could say after positioning 0 (zero) lines (like in COBOL). Read too fast, I view these sometimes as they want the cake and eat it too requests by customers.


Leah
February 08, 2008, 05:15 PM
Watashi
Have a IBI case, they think there may be a couple of solutions. Worst case an image.


7.7.02
Unix
HTLM
February 08, 2008, 05:24 PM
Alan B
Try playing with this technique:
SET CSSURL='http://localhost/tests/dunder.css';
TABLE FILE CAR
PRINT
     CAR
     SALES
BY COUNTRY

ON COUNTRY SUBFOOT WITHIN
" <+0> <SALES"
ON TABLE SET PAGE-NUM OFF
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
     UNITS=IN,
     SQUEEZE=ON,
     ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
     GRID=OFF,
     FONT='ARIAL',
     SIZE=9,
$
TYPE=SUBFOOT,
	 CLASS='dbll',
$
TYPE=SUBFOOT,
     BY=1,
     LINE=1,
     OBJECT=FIELD,
	 CLASS='dblu',
$
ENDSTYLE
END

The CSS file
.dbll {
text-align:right;
padding:0 0 4px 0;
}
.dblu {
text-align:right;
border-bottom:3px double black;
}



Alan.
WF 7.705/8.007
February 11, 2008, 08:58 AM
mgrackin
Frank,

I have a few reports in which I use your technique to combine total lines into the data set so they are treart as data records. this then allows you to apply formating on the total values using TYPE=DATA. this would probably work. However, the necessaity for doing this technique is based on the fact that you cannot do the formatting that is desired on a SUBFOOT.

Alan's solution would work but is limited to HTML output and the double underline varies depending on the length of the total value. Nice solution though, Alan.


Thanks!

Mickey

FOCUS/WebFOCUS 1990 - 2011
February 11, 2008, 09:12 AM
mgrackin
Here's a working example of the technique Frank suggested.

TABLE FILE CAR
SUM RETAIL_COST DEALER_COST
COMPUTE SORTORDER/I1=9;
BY COUNTRY
ON TABLE HOLD AS CARTTL
END

DEFINE FILE CAR
SORTORDER/I1=0;
END

TABLE FILE CAR
PRINT RETAIL_COST DEALER_COST
BY COUNTRY
BY SORTORDER NOPRINT
ON COUNTRY SUBFOOT
" "
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
TYPE=REPORT, GRID=OFF,$
TYPE=DATA, BORDER-STYLE=DOUBLE, BORDER-TOP=MEDIUM,
WHEN=SORTORDER EQ 9,$
ENDSTYLE
MORE
FILE CARTTL
END


Thanks!

Mickey

FOCUS/WebFOCUS 1990 - 2011