Report.getSheets

Syntax

getSheets (onlyVisible)

Parameters

onlyVisible. Determines whether to get descriptions of hidden report sheets. If this parameter is set to True, descriptions are returned only for visible report sheets. Optional parameter.

Description

The getSheets method returns the array of report sheets descriptions.

Comment

This method returns an array of JSON objects that contains descriptions of regular report sheets.

A JSON object has the following fields:

Field name Type Brief description
dataChange Object Object containing the isDataChanged field that indicates if the data in the report sheet has been changed.
id String Report sheet ID.
isActive Boolean Indicates if the report sheet is open: True  - open, False - closed.
k Number Report sheet key.
n String Report sheet name.
vis Boolean Indicates whether the report sheet is visible: True - report sheet is visible, False - the sheet is hidden.

Example

The ReportBox component which source is the Report class with the PrxReport name is required on the HTML page to execute an example (see  Example of the ReportBox Component Layout). Add the DataAreaView.ActiveSheetChanged event handler:

        reportBox.getDataAreaView().ActiveSheetChanged.add(function (sender, args) {
            prxReport.getSheets()[prxReport.getActiveSheetIndex()].n = "New Name";
            reportBox.refresh();
        })

The name of the opened report sheet is changed to the New Name when changing the active report sheet after an example execution.

See also:

Report