Setting the ALPHA Background Color of an Active Technologies Report

How to:

You can set the ALPHA background color of an active report or chart, and each report or chart object on an active dashboard, so that the color is transparent. The ALPHA background color includes the background color of the data in the report or chart, and alternating background colors. This capability enables you to place an image in the background of a report or chart. For example, you can add a watermark behind a report.

This feature applies to all Active Technologies output formats (AHTML, FLEX, and APDF).

In the remainder of this topic, the terminology active report or report includes active chart.

In the following example, the ALPHA background color of the tabular report on the left of the active dashboard is set so that the color is transparent. The image of the message confidential is placed in the background of the tabular report.


Top of page

x
Syntax: How to Set the ALPHA Background Color in a TABLE or GRAPH Request

For a stand-alone active report, use the following WebFOCUS StyleSheet syntax

ON {TABLE|GRAPH} SET STYLE *
TYPE=REPORT, ALPHA=alpha,$
TYPE=REPORT, OBJECT=IMAGE, IMAGE=image_file, POSITION=(x y),$

where:

alpha

Is a value from 0 to 100. It controls the transparency of the background color of the report.

image_file

Is the name of the image file that you want to place in the background of the report. The image may be a watermark. GIF, JPG, and PNG image formats are supported.

x

Is the position of the image from the left edge of the report, in the units of measurement set for the report (for example, inches, centimeters, or points). You can set the units of measurement for a report using the UNITS keyword in your WebFOCUS code or using a graphical tool, such as Report Painter or InfoAssist. For more information, see the applicable reporting language and reporting tools manuals.

y

Is the position of the image from the top edge of the report, in the units of measurement set for the report.

The following example sets the ALPHA background color of an active report to 50.

ON TABLE SET STYLE *
TYPE=REPORT, ALPHA=50,$
TYPE=REPORT, OBJECT=IMAGE, IMAGE=confidential.png, POSITION=(1 1),$

Top of page

x
Syntax: How to Set the ALPHA Background Color in a COMPOUND Request

For a COMPOUND request, use the following syntax

COMPONENT='name_of_report',
.
.
.
ALPHA=alpha,$

where:

name_of_report

Is the name of the report.

alpha

Is a value from 0 to 100. It controls the transparency of the background color of the report.

An example is:

COMPONENT='report1', TEXT='report1', TOC-LEVEL=2, POSITION=(1.250 0.522),
DIMENSION=(6.250 5.525), METADATA='Z-INDEX: 100; POSITION: absolute;
WIDTH: 6.25in; HEIGHT: 5.525in; TOP: 0.522in; LEFT: 1.25in', ALPHA=50,$
OBJECT=IMAGE, NAME='watermark', IMAGE=confidential.png,
POSITION=(2.186 1.454), DIMENSION=(8.150 6.150), METADATA='Z-INDEX: 100;
POSITION: absolute; WIDTH: 4.15in; HEIGHT: 3.15in; TOP: 1.454in;
LEFT: 2.186in',$

The following two examples show the varying transparency generated from different values of ALPHA. In the first example, the value of ALPHA is 40.

In the next example, the value of ALPHA is 60.


WebFOCUS