Render Method

Occurs when ReportListener is ready to provide output for a layout element in a report or label.

oReportListener.Render(nFRXRecNo,;
                       nLeft,nTop,nWidth,nHeight,;
                       nObjectContinuationType, ;
                       cContentsToBeRendered, GDIPlusImage)

Parameters

nFRXRecno

Specifies the record number in the report or label definition file (frx or lbx) describing the layout element being rendered.

nLeft

Specifies the column coordinate, in units of 1/960 inch (960 dpi), of the rectangle on the current page in which this occurrence of the layout element will be rendered.

nTop

Specifies the row coordinate, in units of 1/960 inch (960 dpi), of the rectangle on the current page in which this occurrence of the layout element will be rendered.

nWidth

Specifies the width, in units of 1/960 inch (960 dpi), of the rectangle on the current page in which this occurrence of the layout element will be rendered.

nHeight

Specifies the height, in units of 1/960 inch (960 dpi), of the rectangle on the current page in which this occurrence of the layout element will be rendered.

nObjectContinuationType

Indicates the current continuation state for the rendered element. When layout elements span pages, they are rendered in multiple sections (once for each page).

NoteNote

Continuation can occur for layout elements of Expression (Field), Shape, or Line type. Although Labels and Pictures can span bands in a report, they cannot span pages and ReportListener renders them only once. Not all band types support spanning pages. Refer to Report Bands for more information.

The following table lists the possible values for nObjectContinuationType.

Value Continuation Type

0

Complete (no continuation).

1

Start of layout element occurrence, will not finish on the current page.

2

Mid-element, neither started nor finished on the current page.

3

End of element, completed on the current page.

cContentsToBeRendered

Indicates the text to be rendered for Expression (Field) and Label layout elements. For Picture layout elements sourced from a file, cContentsToBeRendered contains the filename.

When specifying a filename for an image, ReportListener provides cContentsToBeRendered as a DBCS string, which is the standard format for strings in Visual FoxPro. However, when indicating text to be rendered, ReportListener provides cContentsToBeRendered as a Unicode string, appropriately translated to the correct locale using any regional script information associated with this layout control in its report definition file (frx) record.

If your derived class sends the text value through some additional processing, such as storage in a table, you can use the STRCONV() function, and its optional regional script parameter, to convert the string to DBCS first. For more information, see STRCONV( ) Function.

NoteNote

You set the default regional script for a report in the Report Properties dialog box. For more information, see Page Layout Tab, Report Properties Dialog Box (Report Builder). You can also set regional script settings for individual layout controls, when you select other font attributes. For more information, see How to: Change Font Settings in Report Controls.

GDIPlusImage

Provides a handle to the GDI+ graphics handle when a Picture layout is sourced from a non-file-based image (a General field or an Image control).

When the ReportListener renders a different type of layout element, or when you do not set the value of its SendGDIPlusImage property to 1 or higher, this parameter has the value 0. For more information, see SendGDIPlusImage Property.

Expand imageReturn Value

Expand imageRemarks

Expand imageExample

Expand imageSee Also


© , 1996-2020 • Updated: 11/10/20
Comment or report problem with topic