A script-enabled browser is required for this page to function properly.

SRW.SET_BEFORE_REPORT_HTML built-in procedure

This procedure inserts any text, graphics, or HTML commands that you want to appear at the beginning of your document. This attribute is useful for placing a logo or some standard links at the beginning of an HTML document.

If you use HTML page streaming, this procedure applies to the first page of your report output. To specify HTML to apply to the entire report (for example, background color or images, or any other <body> HTML attributes), you must use the SRW.SET_BEFORE_PAGE_HTML PL/SQL procedure.

Syntax


SRW.SET_BEFORE_REPORT_HTML(type,'string');

Parameters

Parameter

Description

type

Is SRW.FILE_ESCAPE or SRW.TEXT_ESCAPE. It indicates whether the string parameter is a filename or the text to be inserted.

string

Is a filename or the text to be inserted, depending on what you specified for the type parameter.

GUI access

You can also define this attribute using the Reports Builder user interface:

Property Inspector

Set the Before Report Type and Before Report Value properties.

Restrictions

<html>
<body bgcolor="#ffffff">

Example

The example below sets both the before and after report escapes in the Before Report trigger. The HTML for the before escape is located in a file named logo.htm. The HTML for the after report escape is specified within the PL/SQL itself.

function BeforeReport return boolean is
begin
if ((upper(:MODE) != 'CHARACTER') and 
(upper(:DESFORMAT) = 'HTML')) then
 SRW.SET_BEFORE_REPORT_HTML(SRW.FILE_ESCAPE,'logo.htm');
 SRW.SET_AFTER_REPORT_HTML(SRW.TEXT_ESCAPE,'<ADDRESS>' ||
       ' Questions? - ' || 
       '<A HREF=mailto:webmaster@xyztech.com>' ||
       'webmaster@xyztech.com</A>'  ||
       '</ADDRESS>' ||
       '</body></html>'); 
 end if;
return (TRUE);
end;

See also

About the Reports Builder built-in package (SRW)

SRW built-in package