Chart.SuppressExceptions Property

.NET Framework (current version)

The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

Gets or sets a flag that determines whether noncritical exceptions should be suppressed.

Namespace:   System.Web.UI.DataVisualization.Charting
Assembly:  System.Web.DataVisualization (in System.Web.DataVisualization.dll)

public bool SuppressExceptions { get; set; }

Property Value

Type: System.Boolean

true if non-critical exceptions should be suppressed; otherwise, false. The default value is false.

If you set this property to true, non-critical exceptions will be suppressed.

When the Chart control cannot properly plot the chart using the data and other settings provided, an exception will be thrown. Although displaying exceptions is useful during application testing, they should not be shown when the application is released.


Setting this property to true may hide serious issues in the user application source code. This setting could also cause a chart image to be generated that might misrepresent your data. It is highly recommended that this mode be only used in Release builds.

.NET Framework
Available since 4.0
Return to top