Report frame Id

Every direct link contains an InstanceID parameter. By default, its value is set to 1. It appears in the DirectLink URL as:

InstanceID=1

This parameter specifies the unique identifier for the frame in which the report is displayed. The ID relates a specific frame in the web browser with a specific spreadsheet in the WebHost process on the web server. So, if a web page contains more than one direct link, each direct link must have a separate InstanceID.

Example

Portal.html contains three IFrame html elements that display three Application Studio WebServices reports.

Each IFrame contains a DirectLink URL that points to a report on the Application Studio WebServices web server.

On the client, the portal page is hosted in one browser instance. This corresponds to one server session and one WebHost.exe worker process.

The WebHost process hosts three spreadsheets; each spreadsheet corresponds to one report.

The report frame ID is used to relate reports in the client or browser to the corresponding WebHost spreadsheet modules on the server. For example, if the user drills down the report hosted in frame 2 then the browser sends a drilldown request to the WebHost with InstanceID=2.

Notes

  • The IDs must be unique.
  • The IDs need not be consecutive integers, for example, 1,2,3, etc. It is only important that they are unique.
  • The ID is not related to the report. It links a specific frame in the browser with a specific spreadsheet in WebHost on the web server.
  • The number of IDs can change. You can programmatically add an IFrame to a portal page at run time and assign a direct link to it. This will create a new spreadsheet instance in the WebHost on the server.

There are two kinds of portal:

  • with a constant number of IFrames. The number of IDs equals the number of IFrames. In this case you define the IDs once.
  • with a variable number of IFrames. IFrames can be created and destroyed programmatically in the client and assigned to direct links. In this case the ID must also be assigned programmatically.

It is the responsibility of the portal developer to maintain the IDs.

Example

Three IFrames (with InstanceIDs 1, 2 and 3) host three reports (Report1, Report2 and Report3).

The portal developer adds a fourth frame to host Report4 but assigns it a direct link with InstanceId=3.

Report4 overwrites the spreadsheet corresponding to Report3 on the server

If the user triggers a request in Report3, for example, selects from a combo box, the request fails.