Register Services in the Report Designer
- 5 minutes to read
You can register custom and/or predefined services to provide specific functionality to the Web Report Designer and its built-in Document Preview.
Services for the Report Designer
Custom Services
Use the DefaultReportDesignerContainer class methods to register the following services in the Report Designer:
Service
Description
Registration Methods
Resolves report IDs for reports and subreports. Has priority over the ReportStorageWebExtension.GetData method.
Enables you to manage data connections used by the Data Source Wizard.
RegisterDataSourceWizardConnectionStringsProvider<T>
RegisterDataSourceWizardConfigFileConnectionStringsProvider (to use the data source connections from the application’s configuration file).
Implements a custom encryption mechanism for string data.
ServiceCollectionServiceExtensions class methods
Allows you to implement a custom encryption mechanism to store data source connection strings on the client.
ServiceCollectionServiceExtensions class methods
Supports automatic creation of the database schema provider (implemented by the IDBSchemaProviderEx interface).
Provides functionality to customize the the Web Report Designer’s Data Source Wizard.
Enables you to handle server-side errors in the Report Designer.
Enables you to change the report settings before the End User Report Designer displays it in the Preview tab.
Returns an array of types that should be listed in the Report Wizard and Data Source Wizard. Users can select one of these types to supply data to reports.
See the following help topic for more information: Register Types for Object Data Source Wizard.Generates a list of type constructors. Users can select one of these constructors in the Report Wizard and Data Source Wizard to create an object data source.
See the following help topic for more information: Register Types for Object Data Source Wizard.Generates a list of type members. Users can select one of these members in the Report Wizard and Data Source Wizard to supply data to reports.
See the following help topic for more information: Register Types for Object Data Source Wizard.A service that allows you to apply row-level filtering to all SELECT queries for the Document Viewer, Report Designer Preview, and Query Builder components. For more information review the following help topic: Multi-Tenant Support (Row Filtering in Shared SQL Database).
Allows you to specify the JsonDataSource.SchemaDiscoveryMaxItemCount property value.
Predefined Services
The following methods of the DefaultReportDesignerContainer register predefined services that override the default Report Designer behavior:
Method Description DefaultReportDesignerContainer.EnableCustomSql Allows the user to edit custom SQL queries in the Data Source Wizard. Report Storage Extension
To define how reports are stored on the server side of your web application, create a descendant from the ReportStorageWebExtension class and use the static ReportStorageWebExtension.RegisterExtensionGlobal method to register it.
Services for the Report Designer’s Preview
Custom Services
You can use the DefaultWebDocumentViewerContainer class methods to register the following custom services that extend the Report Designer’s Preview functionality:
Service
Description
Registration Methods
Enables you to implement access permissions for reports and documents in the Report Designer’s Preview.
Enables you to implement authorized access to reports and documents for the Report Designer’s Preview.
Allows you to log events that occur when the Report designer’s Preview loads and processes a report. You can modify a report or a document, or perform any action when an event occurs.
Adds drill-through functionality to web reports.
Resolves reports that can be displayed by the Web Document Viewer. Does not operate in asynchronous mode.
Allows you to perform custom operations on the Document Viewer’s currently opened document.
Allows you to restore a data connection on report deserialization.
Enables you to handle server-side errors in the Web Document Viewer.
Allows you to override the default URI that a browser uses to get an export result.
Enables you to set the time to clean the document and report storage.
Allows you to set the time to clean the cache that stores documents and reports.
Predefined Services
Use the following methods of the DefaultWebDocumentViewerContainer to register the corresponding predefined services:
Method Description DefaultWebDocumentViewerContainer.UseFileDocumentStorage Specifies a path and synchronization mode for the report document’s file storage. DefaultWebDocumentViewerContainer.UseEmptyStoragesCleaner Replaces the service used to clean the report and document storage with an empty service, so that the storage is not automatically cleaned. DefaultWebDocumentViewerContainer.EnablePassingExportOptionsPasswordsToClient Passwords for PDF/Excel export (specified in the End User Report Designer or stored in the REPX file) are not passed to the Report Designer’s Preview unless this method is called at application startup.
Common Services for HTML5 Controls
You can use the DefaultClientControlContainer class to register the following custom services common to HTML5 controls:
Service | Description | Registration Method |
---|---|---|
IGlobalizationService | Enables you to customize globalization settings of the current thread (including thread impersonation). | UseCustomGlobalizationService<T> |