This is a migrated thread and some comments may be shown as answers.

RadCartesianChart Data refresh.

3 Answers 275 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Lee
Top achievements
Rank 1
Lee asked on 14 May 2014, 12:53 AM
Hi.

I have one problem.

My source is below.

             <telerik:RadCartesianChart.SeriesProvider>
                <telerik:ChartSeriesProvider Source="{Binding Series}">
                    <telerik:ChartSeriesProvider.SeriesDescriptors>
                        <telerik:CategoricalSeriesDescriptor ItemsSourcePath="Data" ValuePath="Value" CategoryPath="LocalTime">
                            <telerik:CategoricalSeriesDescriptor.Style>
                                <Style TargetType="telerik:LineSeries">
                                    <Setter Property="StrokeThickness" Value="1"/>
                                    <Setter Property="Visibility" Value="{Binding Name , Converter={StaticResource pointFocusConverter}}"/>
                                    <Setter Property="ShowLabels" Value="{Binding Path=DataContext.Ribbon.IsShowLabel, RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}"/>
                                    <Setter Property="LegendSettings">
                                        <Setter.Value>
                                            <telerik:SeriesLegendSettings Title="{Binding Name}" />
                                        </Setter.Value>
                                    </Setter>
                                    <Setter Property="VerticalAxis">
                                        <Setter.Value>
                                            <MultiBinding Converter="{StaticResource multiVerticalAxisConverter}">
                                                <Binding Path="Data"/>
                                                <Binding Path="DataContext.Series" ElementName="lineChart"/>
                                            </MultiBinding>
                                        </Setter.Value>
                                    </Setter>
                                </Style>
                            </telerik:CategoricalSeriesDescriptor.Style>
                        </telerik:CategoricalSeriesDescriptor>
                    </telerik:ChartSeriesProvider.SeriesDescriptors>
                </telerik:ChartSeriesProvider>
            </telerik:RadCartesianChart.SeriesProvider>


Currently, good work.

But I want to wort setter about [Property="VerticalAxis"]

Now chart is changed by changing [ItemsSourcePath="Data"]

But converter of 'VerticalAxis' do not work.

Why is this not work?

What should I do for working of converter ?

3 Answers, 1 is accepted

Sort by
0
Petar Marchev
Telerik team
answered on 16 May 2014, 08:45 AM
Hi Lee,

Thank you for the provided code snippet. I created a small test project based on it. Everything works as expected. I debugged the multibinding converter and the proper values are passed to it. I have attached this project for you to check it out. Let us know if you have any additional questions.

Regards,
Petar Marchev
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
0
Lee
Top achievements
Rank 1
answered on 19 May 2014, 02:45 AM
Thank you for reply.

I wonder one thing.

Currently, my code is using timer.

So chart is refreshed.

But precessing is slow.

What should I do for faster processing.
0
Petar Marchev
Telerik team
answered on 21 May 2014, 06:57 AM
Hello Lee,

Can you share with us more information?

1. How many series do you have?

2. Do you know the number of series in advance?

3. How many data items does a series have?

4. How often do the items source change?

5. What are the changes? Do you add new items, remove new items or update present items' values?

6. What render options do you use? Have you tried bitmap or direct2D (you can find a direct2D demo in our WPF QSF examples)?

7. What makes you think that it is the processing that is slower? Are you sure its not the drawing part that is slower?


Regards,
Petar Marchev
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Tags
Chart
Asked by
Lee
Top achievements
Rank 1
Answers by
Petar Marchev
Telerik team
Lee
Top achievements
Rank 1
Share this question
or