How to: Color Dashboard Item Elements in the ASP.NET Web Forms Dashboard Control

The following example demonstrates how to color dashboard item elements using the ASPxClientDashboard.ItemElementCustomColor event.

In this example, chart series points, whose values exceed specified thresholds, are colored in green. Chart series points, whose values fall below specified thresholds, are colored in red.Pie segments, whose contributions in total fall below the specified threshold, are colored in orange.

using System;

namespace ASPxDashboard_ElementCustomColor
{
    public partial class WebForm1 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            ASPxDashboard1.DashboardXmlPath= Server.MapPath("App_Data/dashboard1.xml");
        }
    }
}