Hi,
I wanted to add the winform's chart control (Namespace:System.Windows.Forms.DataVisualization.Charting) into the WPF, but I am not able to add it. My existing XAML code looks like this;
<Windowx:Class="FlowMovementUsingProgressBar.MainWindow"xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"xmlns:wf="clr-namespace:System.Windows.Forms;assembly=System.Windows.Forms"xmlns:MSChart="clr-namespace:System.Windows.Forms.DataVisualization.Charting;assembly=System.Windows.Forms.DataVisualization"xmlns:wfi="clr-namespace:System.Windows.Forms.Integration;assembly=WindowsFormsIntegration"Title="MainWindow"Height="474"Width="810"xmlns:chartingToolkit="clr-namespace:System.Windows.Controls.DataVisualization.Charting;assembly=System.Windows.Controls.DataVisualization.Toolkit"><Grid><WindowsFormsHostMargin="482,12,0,65"Name="WfHost"><MSChart:Chartx:Name="MyWinformChart"/></WindowsFormsHost></Grid>
Now when I make various chart operations in my button click event I don't get any update on the screen. Everything is blank. :(
privatevoid button2_Click(object sender, RoutedEventArgs e) { MyChart = this.FindName("MyWinformChart") as Chart;//various chart operations .... .... }
Could some please helpCand let me know how to add MSChart(System.Windows.Forms.DataVisualization.Charting Namespace) in WPF application?
Thanks & Regards,
Anand Shanbhag