• Home
  • Nchart3D
  • NGrid
  • Customers
  • Live demo
  • Download
  • Purchase
  • Blog
  • Support
  • Login
Contact us Terms of service Privacy policy ©   Anjuta Software
Chart stops updating after unlocking device. How to fix it?
by Eugene at 23 Jun. 2016
  1. NChart3D FAQ
  2. Objective-C API
  3. Chart stops updating after unlocking device. How to fix it?

Sometiems iOS relayouts the application's view when the application enters background and this leads to failure of internal graphical context. To prevent this, you have to use the following property of the chart view: isUpdatingEnabled

Disable updating when application enters background and reenable it when application resumes. For this, implement the following methods of your applicatin delegate (assuming you have access to your NChartView instance in the m_chartView variable):

- (void)applicationDidEnterBackground:(UIApplication *)application
{
    m_chartView.isUpdatingEnabled = NO;
}

- (void)applicationWillEnterForeground:(UIApplication *)application
{
    m_chartView.isUpdatingEnabled = YES;
}

Please, note, that if you have many instances of NChartView, you have to switch the isUpdatingEnabled value of each one.

Was this article helpful?

Unfortunately, you can't vote for this article. Please log in to be able to vote.

0 out of 0 found this helpful


Comments


No comments yet.

Please log in to place a comment.