SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, and iOS Chart & Android Chart Components
I’m trying your example Multi-Pane Stock Charts. And if I use your variant of code it works perfectly. To start your variant I use this code:
var wnd = new Window1(); var test = new CreateMultiPaneStockChartsViewModel(); wnd.Chart.ChartPanes = test.ChartPaneViewModels; wnd.Show();
where wnd.Chart.ChartPanes is ObservableCollection of BaseChartPaneViewModel and is binded to SciChartGroup ItemsSource.
But if I try add paneviewmodel via Add method:
var wnd = new Window1(); var test= new CreateMultiPaneStockChartsViewModel(); foreach (var p in test.ChartPaneViewModels) wnd.Chart.ChartPanes.Add(p);
In Window1 I subscribe on ChartPanes.CollectionChanged where I raise OnPropertyChanged event to update binding.
after adding second paneviewmodel I have error: System.NullReferenceException in Abt.Controls.SciChart.Wpf.dll. How Can I add chart panes via Add method in my case?
Second question is in your example doesn’t work correctly panes hiding. If I hit triangle button to hide for example MACD pane it only moves down under scrollbar but does not hide. And if I next hide volume pane it hides but with scrollbar. How to fix this bug?
For second question answer is I looked demo from your site: https://www.scichart.com/Abt.Controls.SciChart.SL.ExampleTestPage.html#/Abt.Controls.SciChart.Example;component/Examples/IWantTo/CreateStockCharts/MultiPane/CreateMultiPaneStockCharts.xaml.
In my project lib version is older (3.4.1)
For first question I’ll try to make a simple project.
Please login first to submit.