Pre loader

Chart doesn't scroll after changing data

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

I have a chart and a radio button group. When I click a button an app will load new data. And it works ok. But sometimes my chart doesn’t scroll to start when data is changed. I changed visibleRange for it. It can be fixed with postDelayed method but is there any good way to fix it?

My code:

enter link description here

Version
4.3.0.4646
  • Yura Khariton
    Can you give more information about why setting of VisibleRange doesn’t work for you? I believe it should work if you correctly calculate Min/Max for VisibleRange.
  • Iliya Mashin
    Using animateVisibleRangeTo helped me. Thanks
  • You must to post comments
0
0

Hi Lliya,

SciChart is designed not to automaticlaly scroll when you append or update data. You will need to do this yourself.

One of two ways:

  1. Set YAxis.setAutoRange(AutoRange.Always). This will ensure the XAXIS is always updated to fit all data. You can use this in combination with FIFO mode dataseries to get a scrolling effect
  2. Manually scroll the XAxis by setting XAxis.setVisibleRange()

For more info about the two techniques, see Tutorial 6 Adding Realtime Updates as well as our documentation on setting VisibleRange.

Best regards,
Andrew

  • 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