Skip to main content
All docs

DataLoadingEventArgs.DataId Property

Gets an object data source’s unique identifier.

Namespace: DevExpress.DashboardCommon

Assembly: DevExpress.Dashboard.v23.1.Core.dll

NuGet Packages: DevExpress.Dashboard.Core, DevExpress.Win.Dashboard.Design


public string DataId { get; }

Property Value

Type Description

An object data source’s identifier.


Use the DataId property to identify the data source for which the event is raised.

This example shows how to bind the ASP.NET MVC Dashboard extension to the Object Data Source and use the DashboardConfigurator.DataLoading event to supply the data source with data:

using System.Web.Routing;
using DevExpress.DashboardWeb;
using DevExpress.DashboardWeb.Mvc;
using DevExpress.DashboardCommon;

namespace DashboardMVC {
    public static class DashboardConfig {
        public static void RegisterService(RouteCollection routes) {

            DashboardFileStorage dashboardFileStorage = new DashboardFileStorage("~/App_Data/Dashboards");
            DataSourceInMemoryStorage dataSourceStorage = new DataSourceInMemoryStorage();
             // Registers an Object data source.
            DashboardObjectDataSource objDataSource = new DashboardObjectDataSource("Object Data Source");
            objDataSource.DataId = "Object Data Source ID";
            dataSourceStorage.RegisterDataSource("objDataSource", objDataSource.SaveToXml());
            DashboardConfigurator.Default.DataLoading += DataLoading;
         private static void DataLoading(object sender, DataLoadingWebEventArgs e) {
            if(e.DataId == "Object Data Source ID") {
                e.Data = Invoices.CreateData();

The following code snippets (auto-collected from DevExpress Examples) contain references to the DataId property.


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