FlexChart | ComponentOne
FlexChart / Understanding FlexChart / FlexChart Types / WPF Line Chart
In This Topic
    WPF Line Chart
    In This Topic

    The Line Chart displays trends over a period of time by connecting different data points in a series with a straight line. It treats the input as categorical information that is evenly spaced along the X-axis.

    You can create the Line Chart by setting the ChartType property to Line in XAML, at design-time, or using code.

    To create the stacking WPF Line Chart, you need to set the Stacking property to Stacked or Stacked100pc.

    WPF Line Chart

    WPF Line Chart

    Below is the code that implements the aforementioned example:

    <c1:C1FlexChart x:Name="flexChart" 
                    ItemsSource="{Binding DataContext.Data}" 
            <c1:Series SeriesName="Sales" 
            <c1:Series SeriesName="Expenses" 
    Copy Code
    flexChart.ChartType = C1.Chart.ChartType.Line;