Pre loader

How do I wire CollectionChanged & SelectedRenderableSeries using MVVM?

Welcome to the SciChart Forums!

  • Please read our Question Asking Guidelines for how to format a good question
  • Some reputation is required to post answers. Get up-voted to avoid the spam filter!
  • We welcome community answers and upvotes. Every Q&A improves SciChart for everyone

WPF Forums | JavaScript Forums | Android Forums | iOS Forums

0
0

My MVVM application can display more than 300 FastLineRenderableSeries on a SciChartSurface. SciChart handles the data and redisplays quite well. Thank you!

My users may mouse click on a series and quickly see the SelectedSeriesStyle change. The application needs to access the SeriesName of the SelectedSeries in the ViewModel for updates to other items in the ViewModel.

I read the topic/posts tagged SelectionSeriesModifier MVVM and the SeriesSource API. My attempts to utilize the CollectionChanged event of SelectedRenderableSeries (not in code-behind) have not had any success. It seems that I should do a OneWayToSource binding from SelectedRenderableSeries to an ObservableCollection<IChartSeriesViewModel> in the ViewModel. I would then like to use an MVVM Light EventToCommand bound to the CollectionChanged event.

Can you provide a demo or workaround on how to actually make this work?

  • You must to post comments
0
0

Hi there,

Please, try subscribing to the IRenderableSeries.SelectionChanged event when you create IChartSeriesViewModels for SeriesSource. It is fired every time series gets selected, and the series can be accessed via the sender param.

Please, let us know if this way is convenient in your case.

Best regards,
Yuriy

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.

Try SciChart Today

Start a trial and discover why we are the choice
of demanding developers worldwide

Start TrialCase Studies