Chart for WPF and Silverlight / Chart Features / Chart View / Setting the Plot Background
In This Topic
Setting the Plot Background
In This Topic

Setting the Plot background is an easy way to add some customization and contrast to your chart.

The following XAML markup allows you to set the background:

XAML
Copy Code
<c1:C1Chart.View>
    <c1:ChartView PlotBackground="#FF343434">
    </c1:ChartView>
</c1:C1Chart.View>

 

You can also set the PlotBackground property in code. Just specify your chart by name, and add the following code to the InitializeComponent() method:

C#
Copy Code
chart.View.PlotBackground = Brushes.BlueViolet;
See Also