Pre loader

SciChart and TabControl issues

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

Hi all,

In my samples (see attached file) I have two tabs in AvalonDock Control. The first tab contains SciChart and DataGrid, the second tab contains button for the generate data. Go to the second tab and clicking on the button come to the first tab. As you can see, data grid works perfectly, but chart not. You can also un comment OnButtonCommand in the constructor and you will be see that the chart is working correctly. How can I resolve this problem?

UPDATE:

After Yuriy’s Comment, I tried this

public class SciChartSurfaceEx : SciChartSurface
{
   public override void OnApplyTemplate()
   {
       base.OnApplyTemplate();

       IsVisibleChanged += OnVisibleChanged;
   }

   private void OnVisibleChanged(object sender, DependencyPropertyChangedEventArgs e)
   {
       foreach (var renderableSeries in RenderableSeries)
       {
           renderableSeries.DataSeries.InvalidateParentSurface(RangeMode.None);
           renderableSeries.DataSeries.InvalidateParentSurface(RangeMode.ZoomToFit);
           renderableSeries.DataSeries.InvalidateParentSurface(RangeMode.ZoomToFitY);
       }
            
       ViewportManager.InvalidateParentSurface(RangeMode.None);
       ViewportManager.InvalidateParentSurface(RangeMode.ZoomToFit);
       ViewportManager.InvalidateParentSurface(RangeMode.ZoomToFitY);

       ZoomExtents();
   }
}

I tried all options, but no effect. Any ideas?

Thanks,
Arthur

Attachments
  • You must to post comments
0
0

[Comment]
Hi,

I just tried the newest SciChart 2.3v, the sample works as expected with it. Which version do you use? Would it be possible for you to upgrade to it?

P.S.: The update is ready, we are going to deploy it within next few days.

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