The requested page is not available for the requested platform. You are viewing the content for Default platform.

How to: Bind ASPxDashboard to an Object Data Source and Provide Data using DataLoading

  • 4 min to read

In this example, the ObjectDataSource.DataSource property specifies the type of a data class. The actual data for this data source is provided by handling the ASPxDashboard.DataLoading event.

Imports System

Namespace WebDesigner_DataLoading
        Public Class Global_asax
            Inherits System.Web.HttpApplication

            Private Sub Application_Start(ByVal sender As Object, ByVal e As EventArgs)
                AddHandler DevExpress.Web.ASPxWebControl.CallbackError, AddressOf Application_Error
            End Sub

            Private Sub Application_End(ByVal sender As Object, ByVal e As EventArgs)
                ' Code that runs on application shutdown
            End Sub

            Private Sub Application_Error(ByVal sender As Object, ByVal e As EventArgs)
                ' Code that runs when an unhandled error occurs
            End Sub

            Private Sub Session_Start(ByVal sender As Object, ByVal e As EventArgs)
                ' Code that runs when a new session is started
            End Sub

            Private Sub Session_End(ByVal sender As Object, ByVal e As EventArgs)
                ' Code that runs when a session ends. 
                ' Note: The Session_End event is raised only when the sessionstate mode
                ' is set to InProc in the Web.config file. If session mode is set to StateServer 
                ' or SQLServer, the event is not raised.
            End Sub
        End Class
End Namespace