Skip to content

DevExpress-Examples/web-forms-dashboard-handle-errors

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Dashboard for Web Forms - How to handle errors

The following example demostrates two approaches on how to handle errors in the ASP.NET Web Forms Dashboard application:

  • How to specify custom text for internal Dashboard errors
  • How to throw a custom exception during a server-side processing and display the error in the Dashboard error toast

How to specify custom text for internal Dashboard errors

Files to Review

Description

The dashboard in this project contains invalid data connection. This example shows how to use the ASPxWebControl.CallbackError event to override the default text in the exception. The exception occurs when a control tries to load data.

Handle the ASPxWebControl.CallbackError event and specify the callback error message. You can specify the displayed text depending on whether the application is in development mode.

How to throw a custom exception during a server-side processing and display the error in the Dashboard error toast

Files to Review

Description

This example shows how to throw a custom exception when a control loads a dashboard. This example uses the ASPxWebControl.CallbackError event. The ASPxWebControl.SetCallbackErrorMessage method specifies the message text to be displayed for remote clients when a DevExpress control callback error has occurred.

  1. Handle the ASPxWebControl.CallbackError event and specify the callback error message. The displayed text depends on whether the application is in development mode.
  2. To throw an exception when the control loads a dashboard, create custom dashboard storage and override the LoadDashboard method.

Documentation

More Examples

Does this example address your development requirements/objectives?

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

About

How to handle errors in the ASP.NET Web Forms Dashboard application

Topics

Resources

License

Stars

Watchers

Forks

Contributors 3

  •  
  •  
  •