Skip to content

Latest commit

 

History

History
51 lines (34 loc) · 4.07 KB

File metadata and controls

51 lines (34 loc) · 4.07 KB

Dashboard for ASP.NET Core - How to create new JSON data sources at runtime

You can provide end users with the capability to create a new data connection for a JSON Data Source at runtime.

Example Overview

Server

On the server side, implement the IDataSourceWizardConnectionStringsStorage interface to provide an end user with the capability to save the created JSON data connections. Use the created class instance as the ASPxDashboard.SetConnectionStringsProvider / DashboardConfigurator.SetConnectionStringsProvider method's parameter.

Client

To enable the capability for end users, set the allowCreateNewJsonConnection property to true:

Platform API
HTML JavaScript DataSourceWizardExtensionOptions.allowCreateNewJsonConnection
ASP.NET Core DataSourceWizardOptionBuilder.AllowCreateNewJsonConnection(Boolean)
MVC DashboardExtensionSettings.AllowCreateNewJsonConnection
Web Forms ASPxDashboard.AllowCreateNewJsonConnection

After that, the "Choose Connection (JSON)" page allows end users to create new data connections:

Can create new data connections

You can use our test JSON files to try this approach: DataSources.

Files to Review

Documentation

Does this example address your development requirements/objectives?

(you will be redirected to DevExpress.com to submit your response)