Skip to main content
A newer version of this page is available. .

ASPxDashboard.SetDashboardStorage(IDashboardStorage) Method

Specifies a custom storage of dashboards for the Web Dashboard.

Namespace: DevExpress.DashboardWeb

Assembly: DevExpress.Dashboard.v18.2.Web.WebForms.dll

Declaration

public void SetDashboardStorage(
    IDashboardStorage dashboardStorage
)

Parameters

Name Type Description
dashboardStorage IDashboardStorage

An object implementing the IDashboardStorage interface that is the custom storage of dashboards.

Example

The following example shows how to create a custom dashboard storage for ASPxDashboard by implementing the IEditableDashboardStorage interface. In this example, a DataSet is used as an in-memory storage of dashboards. This DataSet can be used later to save dashboards in the database using DataAdapter.

Imports System
Imports System.Collections.Generic
Imports System.Data
Imports System.Linq
Imports System.Web

Namespace WebDesigner_CustomDashboardStorage
    Public Class DashboardStorageDataSet
        Inherits DataSet

        Public Sub New()
            Dim table As New DataTable("Dashboards")
            Dim idColumn As New DataColumn("DashboardID", GetType(Int32))
            idColumn.AutoIncrement = True
            idColumn.AutoIncrementSeed = 1
            idColumn.Unique = True
            idColumn.AllowDBNull = False
            table.Columns.Add(idColumn)
            table.Columns.Add("DashboardXml", GetType(String))
            table.Columns.Add("DashboardName", GetType(String))
            table.PrimaryKey = New DataColumn() {idColumn}
            Me.Tables.Add(table)
        End Sub
    End Class
End Namespace

The following code snippets (auto-collected from DevExpress Examples) contain references to the SetDashboardStorage(IDashboardStorage) method.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also