Binding a model property to CategoricalDataPoint in Radcartesianchart

2 posts, 0 answers
  1. rakesh
    rakesh avatar
    5 posts
    Member since:
    May 2015

    Posted 12 Jun 2015 Link to this post

    Hi, 

    I am using RadCartesian Bargraph(Cluster) to visualize data. I have a model class with certain properties which holds the value for CategoricalDataPoint of each bar in cluster.

    however, when I bind this CategoricalDataPoint value to the property of model class. I get error A 'Binding' cannot be set on the 'Value' property of type telerik:CategoricalDataPoint.  This is my xaml

     <telerik:BarSeries CombineMode="Cluster">
                                <telerik:BarSeries.DataPoints>
                                    <telerik:CategoricalDataPoint Category="today" Value="{Binding Propertyxxx}"/>
                                    
                                    <telerik:CategoricalDataPoint Category="day-1" Value="{Binding Propertyyyy}"/>
                                    
                                </telerik:BarSeries.DataPoints>

    Please help me how to solve this issue as soon as possible.

    Regards,

    Rakesh.N

  2. Martin
    Admin
    Martin avatar
    1099 posts

    Posted 15 Jun 2015 Link to this post

    Hello Rakesh,

    The described error appears because the properties (including Value) are not dependency properties which means that they cannot be bound. Instead you can consider using a data binding pattern to populate the chart's series.

    Regards,
    Martin
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for WPF is Visual Studio 2017 Ready
Back to Top