I'm using the WPF Toolkit line chart, as sample found
If I use it in a test project (brand new WPF project), it works correctly, but if I use it in my project, it raises me exceptions System.ExecutionEngineException or FatalExecutionEngineError.
I need to add values into the line chart after some calculation, so I pass data as follows:
PointCollection pc = new PointCollection();
pc.Add(new Point(1.5, 2.9));
pc.Add(new Point(12.5, 22.9));
pc.Add(new Point(41.5, 26.9));
this.lineseries.ItemsSource = pc;
and XAML is as follows:
<chartingToolkit:Chart Name="chart" HorizontalAlignment="Left" Margin="24,67,0,0" Title="Chart Title" VerticalAlignment="Top" Width="425" Height="225">
<chartingToolkit:LineSeries x:Name="lineseries" DependentValuePath="X" IndependentValuePath="Y" />
Notice that, in my project, I have other referenced dlls like Xceed.Wpf.Toolkit... Notice also that exception is raised randomly, sometimes before points are shown and sometimes after point visualization on chart.
Is there some way to solve this?