ActiveReports 16 .NET Edition
ActiveReports 16 User Guide / Samples and Walkthroughs / Samples / Web Samples / Custom Store
In This Topic
    Custom Store
    In This Topic

    The Custom Store sample demonstrates the use of custom resources service for ActiveReports Web Designer with an ASP.NET Core back end. This sample contains two different implementations which is based on LiteDB and CosmosDB. By default, LiteDB implementation is used. To be able to use CosmosDB, you should have an Azure Cosmos DB account. For more details regarding the method to use CosmosDB, please refer to the 'howto.md' file placed in the Resources\CosmosDB folder.

    Sample Location

    C#

    https://github.com/activereports/WebSamples16/tree/main/WebDesignerSamples/WebDesigner_CustomStore

    Details

    This sample implements the IResourcesService interface. If you are using any unmanaged resources, you should implement 'IDisposable' interface also. The project consists of the following elements.

    Implementation Folder

    This folder contains the following files and folders.

    Resources Folder

    This folder consists of a 'CosmosDB' folder and 'lite.db' file, which is a database file. CosmosDB folder includes information regarding how to use the CosmosDB in the project. This sample already contains all the necessary code for working with CosmosDB.

    Startup.cs

    In this file, the implemented 'IResourcesService' service is registered. Also, ‘UseCustomStore' method for viewer (app.UseReporting) with 'GetReport' method and 'UseCustomStore' method for designer (app.UseDesigner) with 'IResourcesService' implementation are called as an argument.