Xceed Toolkit Plus for WPF v4.6 Documentation
Series Class
Members  Example 


Xceed.Wpf.Toolkit Assembly > Xceed.Wpf.Toolkit.Chart Namespace : Series Class
Displays a list of DataPoint primitives in an Area of a Chart.
Syntax
'Declaration
 
<StyleTypedPropertyAttribute(Property="FocusVisualStyle", StyleTargetType=System.Windows.Controls.Control)>
<XmlLangPropertyAttribute("Language")>
<UsableDuringInitializationAttribute(True)>
<RuntimeNamePropertyAttribute("Name")>
<UidPropertyAttribute("Uid")>
<TypeDescriptionProviderAttribute(MS.Internal.ComponentModel.DependencyObjectProvider)>
<NameScopePropertyAttribute("NameScope", System.Windows.NameScope)>
Public Class Series 
   Inherits System.Windows.Controls.Control
'Usage
 
Dim instance As Series
[StyleTypedProperty(Property="FocusVisualStyle", StyleTargetType=System.Windows.Controls.Control)]
[XmlLangProperty("Language")]
[UsableDuringInitialization(true)]
[RuntimeNameProperty("Name")]
[UidProperty("Uid")]
[TypeDescriptionProvider(MS.Internal.ComponentModel.DependencyObjectProvider)]
[NameScopeProperty("NameScope", System.Windows.NameScope)]
public class Series : System.Windows.Controls.Control 
Remarks

Use the DataPoints property to add/remove DataPoints manually.

Use the DataPointsSource and DataPointBindings properties to configure databinding for elements.

Example
The following shows how to set up a line chart containing a single Area, which in turn contains a single Series. The DataPoint objects of the Series are manually added to the DataPoints property.
<xctk:Chart>
  <xctk:Chart.Areas>
    <xctk:Area x:Name="_area1" Title="Area #1">
      <xctk:Area.Series>
        <xctk:Series x:Name="_series">
          <xctk:Series.Layout>
            <xctk:LineLayout />
          </xctk:Series.Layout>
          <xctk:Series.DataPoints>
            <xctk:DataPoint X="1" Y="1" Label="Oct" />
            <xctk:DataPoint X="2" Y="2" Label="Jan"/>
            <xctk:DataPoint X="2.5" Y="1.5" Label="Feb" />
            <xctk:DataPoint X="4" Y="1" Label="Jun"/>
            <xctk:DataPoint X="1.5" Y="3" Label="Dec"/>
            <xctk:DataPoint X="5" Y="5" Label="Apr"/>
            <xctk:DataPoint X="3" Y="1" Label="Nov"/>
            <xctk:DataPoint X="4.5" Y="7" Label="Jul"/>
            <xctk:DataPoint X="3.5" Y="4.5" Label="Aug"/>
          </xctk:Series.DataPoints>
        </xctk:Series>
      </xctk:Area.Series>
    </xctk:Area>
  </xctk:Chart.Areas>
</xctk:Chart>
The following demonstrates how to use BindingInfo to set up binding, using the Series.DataPointsSource and Series.DataPointBindings properties.
<Chart:Series DataPointsSource="{Binding Source={StaticResource cvs}}" Template="{StaticResource template}" ShowPointsInLegend="true">
		<Chart:Series.DataPointBindings>
			<Chart:BindingInfo PropertyName="X">
				<Chart:BindingInfo.Binding>
					<Binding Path="Age"/>
				</Chart:BindingInfo.Binding>
			</Chart:BindingInfo>
			<Chart:BindingInfo PropertyName="Y">
				<Chart:BindingInfo.Binding>
					<Binding Path="Skill"/>
				</Chart:BindingInfo.Binding>
			</Chart:BindingInfo>
			<Chart:BindingInfo PropertyName="Label">
				<Chart:BindingInfo.Binding>
					<Binding Path="Name"/>
				</Chart:BindingInfo.Binding>
			</Chart:BindingInfo>
		</Chart:Series.DataPointBindings>
</Chart:Series>
Inheritance Hierarchy

System.Object
   System.Windows.Threading.DispatcherObject
      System.Windows.DependencyObject
         System.Windows.Media.Visual
            System.Windows.UIElement
               System.Windows.FrameworkElement
                  System.Windows.Controls.Control
                     Xceed.Wpf.Toolkit.Chart.Series

Requirements

Target Platforms: Windows 11, Windows 10, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

Series Members
Xceed.Wpf.Toolkit.Chart Namespace